@atomicsmash/compiler 0.7.0 → 0.7.2

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/dist/index.js +10 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -125,7 +125,7 @@ const compiler = webpack({
125
125
  entryPoints[entryName] = {
126
126
  import: path,
127
127
  // Output filenames with content hash for fingerprinting
128
- filename: `${path.replace(`${srcFolder}${pathSeparator}`, "").replace(extname(path), "")}${MODE === "production" ? `.[contenthash]` : ""}.js`,
128
+ filename: `${path.replace(`${srcFolder}${pathSeparator}`, "").replace(extname(path), "").replace("scripts/", "js/")}${MODE === "production" ? `.[contenthash]` : ""}.js`,
129
129
  };
130
130
  });
131
131
  return entryPoints;
@@ -200,7 +200,9 @@ const compiler = webpack({
200
200
  type: "asset/resource",
201
201
  generator: {
202
202
  binary: false,
203
- filename: (pathData) => relative(srcFolder, pathData.filename ?? "").replace(".scss", ".[contenthash].css"),
203
+ filename: (pathData) => relative(srcFolder, pathData.filename ?? "")
204
+ .replace(".scss", ".[contenthash].css")
205
+ .replace("styles/", "css/"),
204
206
  },
205
207
  use: [
206
208
  {
@@ -227,7 +229,9 @@ const compiler = webpack({
227
229
  type: "asset/resource",
228
230
  generator: {
229
231
  binary: false,
230
- filename: (pathData) => relative(srcFolder, pathData.filename ?? "").replace(".css", ".[contenthash].css"),
232
+ filename: (pathData) => relative(srcFolder, pathData.filename ?? "")
233
+ .replace(".css", ".[contenthash].css")
234
+ .replace("styles/", "css/"),
231
235
  },
232
236
  use: [
233
237
  {
@@ -263,6 +267,9 @@ const compiler = webpack({
263
267
  if (entry.key.startsWith("/")) {
264
268
  entry.key = entry.key.slice(1);
265
269
  }
270
+ if (entry.key.startsWith("css/")) {
271
+ entry.key = entry.key.replace("css/", "styles/");
272
+ }
266
273
  if (entry.key.endsWith(".js.js")) {
267
274
  entry.key = entry.key.slice(0, -3);
268
275
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@atomicsmash/compiler",
3
3
  "type": "module",
4
- "version": "0.7.0",
4
+ "version": "0.7.2",
5
5
  "description": "A universal compiler for all Atomic Smash projects.",
6
6
  "keywords": [
7
7
  "cli",