fast-ejs-builder 1.0.2 → 1.0.3

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/build.js +4 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fast-ejs-builder",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
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",
package/src/build.js CHANGED
@@ -159,7 +159,10 @@ async function ejsbuild(code = 0) {
159
159
  };
160
160
 
161
161
  const handleComponentError = (component, error) => {
162
- if (config.components.autoGenerate) {
162
+ if (
163
+ !_e(config.components.dir + `/${component}.ejs`) &&
164
+ config.components.autoGenerate
165
+ ) {
163
166
  _md(config.components.dir + `/${component}`, false);
164
167
  _w(config.components.dir + `/${component}.ejs`, "", false);
165
168
  _ds(`Missing component '${component}' generated.`);