@henderea/static-site-builder 1.10.7 → 1.10.9

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.
@@ -30,37 +30,37 @@ const script = scriptIndex === -1 ? args[0] : args[scriptIndex];
30
30
  const nodeArgs = scriptIndex > 0 ? args.slice(0, scriptIndex) : [];
31
31
 
32
32
  switch(script) {
33
- case 'build':
34
- case 'watch': {
35
- const nodeEnv = script == 'build' ? 'production' : 'development';
36
- const result = spawnSync(
37
- 'node',
38
- nodeArgs
39
- .concat(require.resolve('../scripts/' + script))
40
- .concat(args.slice(scriptIndex + 1)),
41
- { stdio: 'inherit', env: _.extend({}, process.env, { NODE_ENV: nodeEnv, BABEL_ENV: nodeEnv }) }
42
- );
43
- if(result.signal) {
44
- if(result.signal === 'SIGKILL') {
45
- console.log(
46
- 'The build failed because the process exited too early. ' +
33
+ case 'build':
34
+ case 'watch': {
35
+ const nodeEnv = script == 'build' ? 'production' : 'development';
36
+ const result = spawnSync(
37
+ 'node',
38
+ nodeArgs
39
+ .concat(require.resolve('../scripts/' + script))
40
+ .concat(args.slice(scriptIndex + 1)),
41
+ { stdio: 'inherit', env: _.extend({}, process.env, { NODE_ENV: nodeEnv, BABEL_ENV: nodeEnv }) }
42
+ );
43
+ if(result.signal) {
44
+ if(result.signal === 'SIGKILL') {
45
+ console.log(
46
+ 'The build failed because the process exited too early. ' +
47
47
  'This probably means the system ran out of memory or someone called ' +
48
48
  '`kill -9` on the process.'
49
- );
50
- } else if(result.signal === 'SIGTERM') {
51
- console.log(
52
- 'The build failed because the process exited too early. ' +
49
+ );
50
+ } else if(result.signal === 'SIGTERM') {
51
+ console.log(
52
+ 'The build failed because the process exited too early. ' +
53
53
  'Someone might have called `kill` or `killall`, or the system could ' +
54
54
  'be shutting down.'
55
- );
55
+ );
56
+ }
57
+ process.exit(1);
56
58
  }
57
- process.exit(1);
59
+ process.exit(result.status);
58
60
  }
59
- process.exit(result.status);
60
- }
61
- // eslint-disable-next-line no-fallthrough
62
- default:
63
- console.log('Unknown script "' + script + '".');
64
- console.log('Perhaps you need to update static-site-builder?');
65
- break;
61
+ // eslint-disable-next-line no-fallthrough
62
+ default:
63
+ console.log('Unknown script "' + script + '".');
64
+ console.log('Perhaps you need to update static-site-builder?');
65
+ break;
66
66
  }
@@ -131,7 +131,7 @@ let postcssOptions = {
131
131
  };
132
132
 
133
133
  if(ssbConfig.postcssOptions && _.isPlainObject(ssbConfig.postcssOptions)) {
134
- postcssOptions = ssbConfig.postcssOptions;
134
+ postcssOptions = _.defaultsDeep({}, postcssOptions, ssbConfig.postcssOptions);
135
135
  }
136
136
 
137
137
  export default _.defaultsDeep({}, ssbConfig.webpack || {}, {
@@ -239,7 +239,7 @@ let postcssOptions = {
239
239
  };
240
240
 
241
241
  if(ssbConfig.postcssOptions && _.isPlainObject(ssbConfig.postcssOptions)) {
242
- postcssOptions = ssbConfig.postcssOptions;
242
+ postcssOptions = _.defaultsDeep({}, postcssOptions, ssbConfig.postcssOptions);
243
243
  }
244
244
 
245
245
  export default _.defaultsDeep({}, ssbConfig.webpack || {}, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@henderea/static-site-builder",
3
- "version": "1.10.7",
3
+ "version": "1.10.9",
4
4
  "description": "A static site builder",
5
5
  "main": "index.js",
6
6
  "repository": "henderea/static-site-builder.git",
@@ -25,8 +25,7 @@
25
25
  },
26
26
  "type": "module",
27
27
  "dependencies": {
28
- "@babel/core": "^7.20.12",
29
- "babel-core": "^6.26.3",
28
+ "@babel/core": "^7.21.3",
30
29
  "babel-loader": "^9.1.2",
31
30
  "case-sensitive-paths-webpack-plugin": "^2.4.0",
32
31
  "chalk": "^5.2.0",
@@ -35,39 +34,38 @@
35
34
  "css-loader": "^6.7.3",
36
35
  "dotenv": "^16.0.3",
37
36
  "dotenv-expand": "^10.0.0",
38
- "ejs": "^3.1.8",
39
- "eslint": "^8.33.0",
37
+ "ejs": "^3.1.9",
38
+ "eslint": "^8.37.0",
40
39
  "file-loader": "^6.2.0",
41
- "filesize": "^10.0.6",
40
+ "filesize": "^10.0.7",
42
41
  "find-pkg": "^2.0.0",
43
42
  "globby": "^13.1.3",
44
43
  "gzip-size": "^7.0.0",
45
44
  "handlebars": "^4.7.7",
46
45
  "html-webpack-plugin": "^5.5.0",
47
46
  "lodash": "^4.17.21",
48
- "mini-css-extract-plugin": "^2.7.2",
47
+ "mini-css-extract-plugin": "^2.7.5",
49
48
  "moment": "^2.29.4",
50
49
  "moment-locales-webpack-plugin": "^1.2.0",
51
50
  "node-sass": "^8.0.0",
52
- "postcss-loader": "^7.0.2",
53
- "postcss-preset-env": "^8.0.1",
51
+ "postcss-loader": "^7.1.0",
52
+ "postcss-preset-env": "^8.2.0",
54
53
  "recursive-readdir": "^2.2.3",
55
- "sass-loader": "^13.2.0",
54
+ "sass-loader": "^13.2.2",
56
55
  "strip-ansi": "^7.0.1",
57
- "style-loader": "^3.3.1",
56
+ "style-loader": "^3.3.2",
58
57
  "thread-loader": "^3.0.4",
59
58
  "ts-loader": "^9.4.2",
60
- "tsconfig-paths-webpack-plugin": "^4.0.0",
61
- "typescript": "^4.9.5",
62
- "webpack": "^5.75.0",
59
+ "tsconfig-paths-webpack-plugin": "^4.0.1",
60
+ "typescript": "^5.0.2",
61
+ "webpack": "^5.77.0",
63
62
  "webpack-manifest-plugin": "^5.0.0",
64
63
  "workbox-webpack-plugin": "^6.5.4"
65
64
  },
66
65
  "devDependencies": {
67
- "@babel/eslint-parser": "^7.19.1",
68
- "@typescript-eslint/eslint-plugin": "^5.51.0",
69
- "@typescript-eslint/parser": "^5.51.0",
70
- "eslint-config-henderea": "1.1.3",
66
+ "@typescript-eslint/eslint-plugin": "^5.57.0",
67
+ "@typescript-eslint/parser": "^5.57.0",
68
+ "eslint-config-henderea": "1.1.6",
71
69
  "eslint-plugin-import": "^2.27.5"
72
70
  },
73
71
  "eslintConfig": {
@@ -23,8 +23,7 @@ function isLikelyASyntaxError(message) {
23
23
  }
24
24
 
25
25
  // Cleans up webpack error messages.
26
- // eslint-disable-next-line no-unused-vars
27
- function formatMessage(message, isError) {
26
+ function formatMessage(message, _isError) {
28
27
  if(_.isPlainObject(message)) { message = message.message || ''; }
29
28
  var lines = message.split('\n');
30
29