@videinfra/static-website-builder 1.8.0 → 1.9.1

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/CHANGELOG.md CHANGED
@@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
4
4
  The format is based on [Keep a Changelog](http://keepachangelog.com/)
5
5
  and this project adheres to [Semantic Versioning](http://semver.org/).
6
6
 
7
+ ## [1.9.1] - 2023-11-01
8
+ ### Fixed
9
+ - Fixed public path for dynamic imports
10
+
11
+ ## [1.9.0] - 2023-08-16
12
+ ### Updated
13
+ - Downgraded nano-memoize version
14
+
7
15
  ## [1.8.0] - 2023-08-10
8
16
  ### Updated
9
17
  - Dependencies
@@ -11,7 +11,6 @@ exports.icons = {};
11
11
  exports.images = {};
12
12
  exports.javascripts = {};
13
13
  exports.stylesheets = {};
14
- exports.browserSync = false;
15
14
  exports.sizereport = false;
16
15
 
17
16
  exports.plugins = [
package/lib/get-path.js CHANGED
@@ -1,5 +1,5 @@
1
1
  const path = require('path');
2
- const memoize = require('nano-memoize').default;
2
+ const memoize = require('nano-memoize');
3
3
  const getConfig = require('./get-config');
4
4
 
5
5
 
@@ -87,6 +87,18 @@ function getDestPath (name, ...paths) {
87
87
  }
88
88
  }
89
89
 
90
+ /**
91
+ * Returns public path
92
+ *
93
+ * @param {string} [name] Task name
94
+ * @returns {string} Task public path
95
+ */
96
+ function getPublicPath (name) {
97
+ const destFullPath = getDestPath(name);
98
+ const destPath = getDestPath();
99
+ return destFullPath.replace(destPath, '') + '/';
100
+ }
101
+
90
102
 
91
103
  exports.getPathConfig = getPathConfig;
92
104
  exports.getSourcePath = getSourcePath;
@@ -94,3 +106,4 @@ exports.getSourcePaths = getSourcePaths;
94
106
  exports.getDestPath = getDestPath;
95
107
  exports.getProjectPath = getProjectPath;
96
108
  exports.getBuilderPath = getBuilderPath;
109
+ exports.getPublicPath = getPublicPath;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@videinfra/static-website-builder",
3
- "version": "1.8.0",
3
+ "version": "1.9.1",
4
4
  "description": "Customizable static site project builder",
5
5
  "license": "MIT",
6
6
  "engines": {
@@ -52,7 +52,7 @@
52
52
  "gulp-svgstore": "^9.0.0",
53
53
  "gulp-twig": "^1.2.0",
54
54
  "minimist": "^1.2.8",
55
- "nano-memoize": "3.0.13",
55
+ "nano-memoize": "1.3.0",
56
56
  "node-sass": "^7.0.3",
57
57
  "sass": "^1.65.1",
58
58
  "webpack": "^4.46.0",
@@ -1,5 +1,5 @@
1
1
  const gulp = require('gulp');
2
- const memoize = require('nano-memoize').default;
2
+ const memoize = require('nano-memoize');
3
3
 
4
4
  const globs = require('@videinfra/example-website-builder/lib/globs-helper');
5
5
  const getConfig = require('@videinfra/example-website-builder/lib/get-config');
@@ -1,5 +1,5 @@
1
1
  const gulp = require('gulp');
2
- const memoize = require('nano-memoize').default;
2
+ const memoize = require('nano-memoize');
3
3
 
4
4
  const globs = require('./../../lib/globs-helper');
5
5
  const getPaths = require('./../../lib/get-path');
@@ -2,7 +2,7 @@ const gulp = require('gulp');
2
2
  const data = require('gulp-data');
3
3
  const gulpif = require('gulp-if');
4
4
  const htmlmin = require('gulp-htmlmin')
5
- const memoize = require('nano-memoize').default;
5
+ const memoize = require('nano-memoize');
6
6
  const cached = require('gulp-cached');
7
7
  const dependents = require('gulp-dependents');
8
8
  const ignore = require('gulp-ignore');
@@ -2,7 +2,7 @@ const gulp = require('gulp');
2
2
  const gulpif = require('gulp-if');
3
3
  const svgstore = require('gulp-svgstore');
4
4
  const svgmin = require('gulp-svgmin');
5
- const memoize = require('nano-memoize').default;
5
+ const memoize = require('nano-memoize');
6
6
 
7
7
  const globs = require('./../../lib/globs-helper');
8
8
  const getPaths = require('./../../lib/get-path');
@@ -1,5 +1,5 @@
1
1
  const gulp = require('gulp');
2
- const memoize = require('nano-memoize').default;
2
+ const memoize = require('nano-memoize');
3
3
 
4
4
  const globs = require('./../../lib/globs-helper');
5
5
  const getPaths = require('./../../lib/get-path');
@@ -43,7 +43,8 @@ module.exports = function preprocessJavascriptsConfig (config, fullConfig) {
43
43
 
44
44
  // Output folder
45
45
  output: merge({
46
- path: paths.getDestPath('javascripts')
46
+ path: paths.getDestPath('javascripts'),
47
+ publicPath: paths.getPublicPath('javascripts'),
47
48
  }, get(config, ['webpack', 'output'], null)),
48
49
 
49
50
  // Plugins, add ENV variables
@@ -1,7 +1,7 @@
1
1
  const gulp = require('gulp');
2
2
  const webpack = require('webpack');
3
3
  const gulpWebpack = require('webpack-stream');
4
- const memoize = require('nano-memoize').default;
4
+ const memoize = require('nano-memoize');
5
5
 
6
6
  const merge = require('../../lib/merge');
7
7
  const globs = require('./../../lib/globs-helper');
@@ -1,5 +1,5 @@
1
1
  const gulp = require('gulp');
2
- const memoize = require('nano-memoize').default;
2
+ const memoize = require('nano-memoize');
3
3
 
4
4
  const globs = require('./../../lib/globs-helper');
5
5
  const getPaths = require('./../../lib/get-path');
@@ -2,7 +2,7 @@ const gulp = require('gulp');
2
2
  const gulpif = require('gulp-if');
3
3
  const postcss = require('gulp-postcss');
4
4
  const sourcemaps = require('gulp-sourcemaps');
5
- const memoize = require('nano-memoize').default;
5
+ const memoize = require('nano-memoize');
6
6
  const cached = require('gulp-cached');
7
7
  const dependents = require('gulp-dependents');
8
8