silgi 0.7.20 → 0.7.21

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.
@@ -1,4 +1,4 @@
1
- const version = "0.7.20";
1
+ const version = "0.7.21";
2
2
  const packageJson = {
3
3
  version: version};
4
4
 
@@ -1458,7 +1458,7 @@ async function generateApp(app, options = {}) {
1458
1458
  app.templates = Object.values(defaultTemplates).concat(app.options.build.templates);
1459
1459
  await app.callHook("app:templates", app);
1460
1460
  app.templates = app.templates.map((tmpl) => {
1461
- const dir = (tmpl.where === ".silgi" ? app.options.build.dir : tmpl.where === "server" ? app.options.silgi.serverDir : app.options.silgi.clientDir) || app.options.silgi.vfsDir;
1461
+ const dir = tmpl.where === ".silgi" ? app.options.build.dir : tmpl.where === "server" ? app.options.silgi.serverDir : tmpl.where === "client" ? app.options.silgi.clientDir : app.options.silgi.vfsDir;
1462
1462
  return normalizeTemplate(tmpl, dir);
1463
1463
  });
1464
1464
  const filteredTemplates = {
@@ -1477,7 +1477,7 @@ async function generateApp(app, options = {}) {
1477
1477
  const dirs = /* @__PURE__ */ new Set();
1478
1478
  const changedTemplates = [];
1479
1479
  async function processTemplate(template) {
1480
- const dir = (template.where === ".silgi" ? app.options.build.dir : template.where === "server" ? app.options.silgi.serverDir : app.options.silgi.clientDir) || app.options.silgi.vfsDir;
1480
+ const dir = template.where === ".silgi" ? app.options.build.dir : template.where === "server" ? app.options.silgi.serverDir : template.where === "client" ? app.options.silgi.clientDir : app.options.silgi.vfsDir;
1481
1481
  const fullPath = template.dst || resolve(dir, template.filename);
1482
1482
  const start = performance.now();
1483
1483
  const contents = await compileTemplate(template, templateContext).catch((e) => {
@@ -292,7 +292,7 @@ function normalizeTemplate(template, buildDir) {
292
292
  }
293
293
  if (!template.dst) {
294
294
  const silgi = useSilgiCLI();
295
- const dir = template.where === ".silgi" ? silgi.options.build.dir : template.where === "server" ? silgi.options.silgi.serverDir : silgi.options.silgi.clientDir;
295
+ const dir = template.where === ".silgi" ? silgi.options.build.dir : template.where === "server" ? silgi.options.silgi.serverDir : template.where === "client" ? silgi.options.silgi.clientDir : silgi.options.silgi.serverDir;
296
296
  template.dst = resolve(buildDir ?? dir, template.filename);
297
297
  }
298
298
  return template;
@@ -1,3 +1,3 @@
1
- const version = "0.7.20";
1
+ const version = "0.7.21";
2
2
 
3
3
  export { version };
@@ -1,3 +1,3 @@
1
- const version = "0.7.20";
1
+ const version = "0.7.21";
2
2
 
3
3
  export { version };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "silgi",
3
3
  "type": "module",
4
- "version": "0.7.20",
4
+ "version": "0.7.21",
5
5
  "private": false,
6
6
  "sideEffects": false,
7
7
  "exports": {