fast-ejs-builder 0.0.2 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/index.js CHANGED
File without changes
package/core/index.js CHANGED
@@ -26,7 +26,6 @@ const _rd = (dirname) => {
26
26
  };
27
27
  });
28
28
  } catch (e) {
29
- console.log(e);
30
29
  return [];
31
30
  }
32
31
  };
@@ -64,7 +63,6 @@ const _w = (pathname, data, force = false) => {
64
63
  fs.writeFileSync(_p(pathname), parsed, { encoding: "utf8" });
65
64
  return true;
66
65
  } catch (error) {
67
- console.log(error);
68
66
  return false;
69
67
  }
70
68
  };
package/package.json CHANGED
@@ -1,11 +1,16 @@
1
1
  {
2
2
  "name": "fast-ejs-builder",
3
- "version": "0.0.2",
3
+ "version": "0.0.4",
4
4
  "description": "Fast-EJS is a simple and fast tool to pre-render EJS templates into static HTML files with clean conventions and flexible data handling.",
5
5
  "keywords": [
6
6
  "tailwind",
7
7
  "html",
8
- "build"
8
+ "build",
9
+ "ejs",
10
+ "cli",
11
+ "builder",
12
+ "css",
13
+ "template"
9
14
  ],
10
15
  "homepage": "https://github.com/D3R50N/fast-ejs#readme",
11
16
  "bugs": {
@@ -22,10 +27,6 @@
22
27
  "bin": {
23
28
  "fast-ejs": "bin/index.js"
24
29
  },
25
- "scripts": {
26
- "test": "echo \"Error: no test specified\" && exit 1",
27
- "dev": "nodemon index.js"
28
- },
29
30
  "dependencies": {
30
31
  "@inquirer/prompts": "^8.2.0",
31
32
  "autoprefixer": "^10.4.23",
@@ -35,5 +36,9 @@
35
36
  "postcss": "^8.5.6",
36
37
  "prettier": "^3.8.0",
37
38
  "tailwindcss": "^3.4.17"
39
+ },
40
+ "scripts": {
41
+ "test": "echo \"Error: no test specified\" && exit 1",
42
+ "dev": "nodemon index.js"
38
43
  }
39
- }
44
+ }
package/src/build-dev.js CHANGED
@@ -1,9 +1,11 @@
1
1
  const { args, _d, _p } = require("../core");
2
2
  const ejsbuild = require("../src/build");
3
3
  const nodemon = require("nodemon");
4
- const { config } = require("../core/lib");
4
+ const { config, getConfig } = require("../core/lib");
5
5
 
6
6
  async function ejsbuild_dev() {
7
+ await getConfig();
8
+
7
9
  const toWatch = [
8
10
  config.pages.dir,
9
11
  config.components.dir,
@@ -12,7 +14,7 @@ async function ejsbuild_dev() {
12
14
  ];
13
15
 
14
16
  _d("Watching :", toWatch.map((d) => `'${d}'`).join(", "));
15
- await ejsbuild(); // needs await to get config
17
+ ejsbuild(); // no more needs await
16
18
 
17
19
  nodemon({
18
20
  watch: toWatch.map(_p),