@caweb/webpack 1.3.35 → 1.3.37
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 +6 -0
- package/package.json +3 -3
- package/plugins/html/CHANGELOG.md +13 -0
- package/plugins/html/package-lock.json +32 -35
- package/plugins/html/package.json +5 -5
- package/plugins/html/sample/structural/footer.html +1 -1
- package/plugins/html/tsconfig.json +13 -0
- package/plugins/html/webpack.config.js +70 -52
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@caweb/webpack",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.37",
|
|
4
4
|
"description": "CAWebPublishing Webpack Configuration",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -32,12 +32,12 @@
|
|
|
32
32
|
},
|
|
33
33
|
"homepage": "https://github.com/CAWebPublishing/webpack#readme",
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"webpack": "^5.99.
|
|
35
|
+
"webpack": "^5.99.7"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@caweb/a11y-webpack-plugin": "^1.0.9",
|
|
39
39
|
"@caweb/css-audit-webpack-plugin": "^1.0.12",
|
|
40
|
-
"@caweb/html-webpack-plugin": "^1.7.
|
|
40
|
+
"@caweb/html-webpack-plugin": "^1.7.6",
|
|
41
41
|
"@caweb/jshint-webpack-plugin": "^2.0.1"
|
|
42
42
|
}
|
|
43
43
|
}
|
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
v1.7.6
|
|
2
|
+
- Added .tsx rule and ts-loader
|
|
3
|
+
- Added default tsconfig.json config file
|
|
4
|
+
- Removed the WordPress DependencyExtractionPlugin plugin definition
|
|
5
|
+
- Padding to interactive elements changed from .5rem 0 to .5rem
|
|
6
|
+
- Updated npm packages
|
|
7
|
+
|
|
8
|
+
v1.7.5
|
|
9
|
+
- Added sr-only to social share links in the footer template
|
|
10
|
+
- Added text-decoration to a:hover:not(.btn) and a:focus:not(.btn)
|
|
11
|
+
- Removed anchor line-height fix and added padding to anchors to correct interactive element not meeting minimum size or spacing
|
|
12
|
+
- Updated npm packages
|
|
13
|
+
|
|
1
14
|
v1.7.4
|
|
2
15
|
- Increased anchor line-height from 1.5 to 1.75 to correct interactive element not meeting minimum size or spacing
|
|
3
16
|
- Updated npm packages
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@caweb/html-webpack-plugin",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.6",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@caweb/html-webpack-plugin",
|
|
9
|
-
"version": "1.7.
|
|
9
|
+
"version": "1.7.6",
|
|
10
10
|
"license": "ISC",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@caweb/a11y-webpack-plugin": "^1.0.9",
|
|
@@ -20,19 +20,19 @@
|
|
|
20
20
|
"html-webpack-skip-assets-plugin": "^1.0.4",
|
|
21
21
|
"mini-css-extract-plugin": "^2.9.2",
|
|
22
22
|
"rtlcss-webpack-plugin": "^4.0.7",
|
|
23
|
-
"webpack": "^5.99.
|
|
23
|
+
"webpack": "^5.99.7",
|
|
24
24
|
"webpack-cli": "^6.0.1",
|
|
25
25
|
"webpack-remove-empty-scripts": "^1.0.4"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@caweb/icon-library": "^1.0
|
|
29
|
-
"@inquirer/prompts": "^7.
|
|
28
|
+
"@caweb/icon-library": "^1.1.0",
|
|
29
|
+
"@inquirer/prompts": "^7.5.0",
|
|
30
30
|
"animate.css": "^4.1.1",
|
|
31
31
|
"bootstrap": "^5.3.5",
|
|
32
32
|
"bootstrap-forced-colors-css": "^1.0.7",
|
|
33
33
|
"chalk": "^5.4.1",
|
|
34
34
|
"cross-spawn": "^7.0.6",
|
|
35
|
-
"fast-xml-parser": "^5.2.
|
|
35
|
+
"fast-xml-parser": "^5.2.1"
|
|
36
36
|
}
|
|
37
37
|
},
|
|
38
38
|
"node_modules/@ampproject/remapping": {
|
|
@@ -1908,15 +1908,11 @@
|
|
|
1908
1908
|
}
|
|
1909
1909
|
},
|
|
1910
1910
|
"node_modules/@caweb/icon-library": {
|
|
1911
|
-
"version": "1.0
|
|
1912
|
-
"resolved": "https://registry.npmjs.org/@caweb/icon-library/-/icon-library-1.0.
|
|
1913
|
-
"integrity": "sha512-
|
|
1911
|
+
"version": "1.1.0",
|
|
1912
|
+
"resolved": "https://registry.npmjs.org/@caweb/icon-library/-/icon-library-1.1.0.tgz",
|
|
1913
|
+
"integrity": "sha512-FJx8PBXviJo5GQaW9ZBD646RO3qPDisOnIq3cloVE/Cev3EY+SsNeTPXXVob661z9ZWIY2d5VCDDwjhs+03y5g==",
|
|
1914
1914
|
"dev": true,
|
|
1915
|
-
"license": "GPL2"
|
|
1916
|
-
"engines": {
|
|
1917
|
-
"node": ">=18.0.0",
|
|
1918
|
-
"npm": ">=10.0.0"
|
|
1919
|
-
}
|
|
1915
|
+
"license": "GPL2"
|
|
1920
1916
|
},
|
|
1921
1917
|
"node_modules/@caweb/jshint-webpack-plugin": {
|
|
1922
1918
|
"version": "2.0.1",
|
|
@@ -2515,9 +2511,9 @@
|
|
|
2515
2511
|
}
|
|
2516
2512
|
},
|
|
2517
2513
|
"node_modules/@inquirer/prompts": {
|
|
2518
|
-
"version": "7.
|
|
2519
|
-
"resolved": "https://registry.npmjs.org/@inquirer/prompts/-/prompts-7.
|
|
2520
|
-
"integrity": "sha512-
|
|
2514
|
+
"version": "7.5.0",
|
|
2515
|
+
"resolved": "https://registry.npmjs.org/@inquirer/prompts/-/prompts-7.5.0.tgz",
|
|
2516
|
+
"integrity": "sha512-tk8Bx7l5AX/CR0sVfGj3Xg6v7cYlFBkEahH+EgBB+cZib6Fc83dwerTbzj7f2+qKckjIUGsviWRI1d7lx6nqQA==",
|
|
2521
2517
|
"dev": true,
|
|
2522
2518
|
"license": "MIT",
|
|
2523
2519
|
"dependencies": {
|
|
@@ -2528,9 +2524,9 @@
|
|
|
2528
2524
|
"@inquirer/input": "^4.1.9",
|
|
2529
2525
|
"@inquirer/number": "^3.0.12",
|
|
2530
2526
|
"@inquirer/password": "^4.0.12",
|
|
2531
|
-
"@inquirer/rawlist": "^4.0
|
|
2527
|
+
"@inquirer/rawlist": "^4.1.0",
|
|
2532
2528
|
"@inquirer/search": "^3.0.12",
|
|
2533
|
-
"@inquirer/select": "^4.
|
|
2529
|
+
"@inquirer/select": "^4.2.0"
|
|
2534
2530
|
},
|
|
2535
2531
|
"engines": {
|
|
2536
2532
|
"node": ">=18"
|
|
@@ -2545,9 +2541,9 @@
|
|
|
2545
2541
|
}
|
|
2546
2542
|
},
|
|
2547
2543
|
"node_modules/@inquirer/rawlist": {
|
|
2548
|
-
"version": "4.0
|
|
2549
|
-
"resolved": "https://registry.npmjs.org/@inquirer/rawlist/-/rawlist-4.0.
|
|
2550
|
-
"integrity": "sha512-
|
|
2544
|
+
"version": "4.1.0",
|
|
2545
|
+
"resolved": "https://registry.npmjs.org/@inquirer/rawlist/-/rawlist-4.1.0.tgz",
|
|
2546
|
+
"integrity": "sha512-6ob45Oh9pXmfprKqUiEeMz/tjtVTFQTgDDz1xAMKMrIvyrYjAmRbQZjMJfsictlL4phgjLhdLu27IkHNnNjB7g==",
|
|
2551
2547
|
"dev": true,
|
|
2552
2548
|
"license": "MIT",
|
|
2553
2549
|
"dependencies": {
|
|
@@ -2592,9 +2588,9 @@
|
|
|
2592
2588
|
}
|
|
2593
2589
|
},
|
|
2594
2590
|
"node_modules/@inquirer/select": {
|
|
2595
|
-
"version": "4.
|
|
2596
|
-
"resolved": "https://registry.npmjs.org/@inquirer/select/-/select-4.
|
|
2597
|
-
"integrity": "sha512-
|
|
2591
|
+
"version": "4.2.0",
|
|
2592
|
+
"resolved": "https://registry.npmjs.org/@inquirer/select/-/select-4.2.0.tgz",
|
|
2593
|
+
"integrity": "sha512-KkXQ4aSySWimpV4V/TUJWdB3tdfENZUU765GjOIZ0uPwdbGIG6jrxD4dDf1w68uP+DVtfNhr1A92B+0mbTZ8FA==",
|
|
2598
2594
|
"dev": true,
|
|
2599
2595
|
"license": "MIT",
|
|
2600
2596
|
"dependencies": {
|
|
@@ -11188,9 +11184,9 @@
|
|
|
11188
11184
|
"license": "BSD-3-Clause"
|
|
11189
11185
|
},
|
|
11190
11186
|
"node_modules/fast-xml-parser": {
|
|
11191
|
-
"version": "5.2.
|
|
11192
|
-
"resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-5.2.
|
|
11193
|
-
"integrity": "sha512-
|
|
11187
|
+
"version": "5.2.1",
|
|
11188
|
+
"resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-5.2.1.tgz",
|
|
11189
|
+
"integrity": "sha512-Kqq/ewnRACQ20e0BlQ5KqHRYWRBp7yv+jttK4Yj2yY+2ldgCoxJkrP1NHUhjypsJ+eQXlGJ/jebM3wa60s1rbQ==",
|
|
11194
11190
|
"dev": true,
|
|
11195
11191
|
"funding": [
|
|
11196
11192
|
{
|
|
@@ -19300,9 +19296,9 @@
|
|
|
19300
19296
|
}
|
|
19301
19297
|
},
|
|
19302
19298
|
"node_modules/schema-utils": {
|
|
19303
|
-
"version": "4.3.
|
|
19304
|
-
"resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.3.
|
|
19305
|
-
"integrity": "sha512-
|
|
19299
|
+
"version": "4.3.2",
|
|
19300
|
+
"resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.3.2.tgz",
|
|
19301
|
+
"integrity": "sha512-Gn/JaSk/Mt9gYubxTtSn/QCV4em9mpAPiR1rqy/Ocu19u/G9J5WWdNoUT4SiV6mFC3y6cxyFcFwdzPM3FgxGAQ==",
|
|
19306
19302
|
"license": "MIT",
|
|
19307
19303
|
"dependencies": {
|
|
19308
19304
|
"@types/json-schema": "^7.0.9",
|
|
@@ -22006,13 +22002,14 @@
|
|
|
22006
22002
|
}
|
|
22007
22003
|
},
|
|
22008
22004
|
"node_modules/webpack": {
|
|
22009
|
-
"version": "5.99.
|
|
22010
|
-
"resolved": "https://registry.npmjs.org/webpack/-/webpack-5.99.
|
|
22011
|
-
"integrity": "sha512-
|
|
22005
|
+
"version": "5.99.7",
|
|
22006
|
+
"resolved": "https://registry.npmjs.org/webpack/-/webpack-5.99.7.tgz",
|
|
22007
|
+
"integrity": "sha512-CNqKBRMQjwcmKR0idID5va1qlhrqVUKpovi+Ec79ksW8ux7iS1+A6VqzfZXgVYCFRKl7XL5ap3ZoMpwBJxcg0w==",
|
|
22012
22008
|
"license": "MIT",
|
|
22013
22009
|
"dependencies": {
|
|
22014
22010
|
"@types/eslint-scope": "^3.7.7",
|
|
22015
22011
|
"@types/estree": "^1.0.6",
|
|
22012
|
+
"@types/json-schema": "^7.0.15",
|
|
22016
22013
|
"@webassemblyjs/ast": "^1.14.1",
|
|
22017
22014
|
"@webassemblyjs/wasm-edit": "^1.14.1",
|
|
22018
22015
|
"@webassemblyjs/wasm-parser": "^1.14.1",
|
|
@@ -22029,7 +22026,7 @@
|
|
|
22029
22026
|
"loader-runner": "^4.2.0",
|
|
22030
22027
|
"mime-types": "^2.1.27",
|
|
22031
22028
|
"neo-async": "^2.6.2",
|
|
22032
|
-
"schema-utils": "^4.3.
|
|
22029
|
+
"schema-utils": "^4.3.2",
|
|
22033
22030
|
"tapable": "^2.1.1",
|
|
22034
22031
|
"terser-webpack-plugin": "^5.3.11",
|
|
22035
22032
|
"watchpack": "^2.4.1",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@caweb/html-webpack-plugin",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.6",
|
|
4
4
|
"description": "CAWebPublishing Sample Page and Configurations",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -105,14 +105,14 @@
|
|
|
105
105
|
},
|
|
106
106
|
"homepage": "https://github.com/CAWebPublishing/webpack/plugins/html#readme",
|
|
107
107
|
"devDependencies": {
|
|
108
|
-
"@caweb/icon-library": "^1.0
|
|
109
|
-
"@inquirer/prompts": "^7.
|
|
108
|
+
"@caweb/icon-library": "^1.1.0",
|
|
109
|
+
"@inquirer/prompts": "^7.5.0",
|
|
110
110
|
"animate.css": "^4.1.1",
|
|
111
111
|
"bootstrap": "^5.3.5",
|
|
112
112
|
"bootstrap-forced-colors-css": "^1.0.7",
|
|
113
113
|
"chalk": "^5.4.1",
|
|
114
114
|
"cross-spawn": "^7.0.6",
|
|
115
|
-
"fast-xml-parser": "^5.2.
|
|
115
|
+
"fast-xml-parser": "^5.2.1"
|
|
116
116
|
},
|
|
117
117
|
"dependencies": {
|
|
118
118
|
"@caweb/a11y-webpack-plugin": "^1.0.9",
|
|
@@ -126,7 +126,7 @@
|
|
|
126
126
|
"html-webpack-skip-assets-plugin": "^1.0.4",
|
|
127
127
|
"mini-css-extract-plugin": "^2.9.2",
|
|
128
128
|
"rtlcss-webpack-plugin": "^4.0.7",
|
|
129
|
-
"webpack": "^5.99.
|
|
129
|
+
"webpack": "^5.99.7",
|
|
130
130
|
"webpack-cli": "^6.0.1",
|
|
131
131
|
"webpack-remove-empty-scripts": "^1.0.4"
|
|
132
132
|
}
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
{{#each social }}
|
|
23
23
|
{{#if this }}
|
|
24
24
|
<li class="nav-item">
|
|
25
|
-
<a href="{{ this }}" class="nav-link ca-gov-icon-{{ @key }}"></a>
|
|
25
|
+
<a href="{{ this }}" class="nav-link ca-gov-icon-{{ @key }}"><span class="sr-only">{{ @key }}</span></a>
|
|
26
26
|
</li>
|
|
27
27
|
{{/if}}
|
|
28
28
|
{{/each}}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"allowSyntheticDefaultImports": true,
|
|
4
|
+
"outDir": "./scripts/",
|
|
5
|
+
"noImplicitAny": true,
|
|
6
|
+
"module": "es6",
|
|
7
|
+
"target": "es5",
|
|
8
|
+
"jsx": "react",
|
|
9
|
+
"allowJs": true,
|
|
10
|
+
"moduleResolution": "node",
|
|
11
|
+
"resolveJsonModule": true,
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -47,7 +47,7 @@ function processArgs( arr ){
|
|
|
47
47
|
|
|
48
48
|
arr.filter(Boolean).map((o) => {
|
|
49
49
|
return o.replaceAll("'", '').split('=').forEach((e => tmp.push(e)))
|
|
50
|
-
|
|
50
|
+
});
|
|
51
51
|
|
|
52
52
|
return tmp
|
|
53
53
|
}
|
|
@@ -94,6 +94,10 @@ baseConfig.module.rules.forEach((rule, i) => {
|
|
|
94
94
|
// instead we use the Webpack output.clean definition
|
|
95
95
|
baseConfig.plugins.splice(1,1, false);
|
|
96
96
|
|
|
97
|
+
// We remove the WordPress DependencyExtractionPlugin definition
|
|
98
|
+
// otherwise externals are not available in the global scope
|
|
99
|
+
baseConfig.plugins.pop();
|
|
100
|
+
|
|
97
101
|
/**
|
|
98
102
|
* we remove the WordPress devServer declaration since we can only have 1 when exporting multiple configurations
|
|
99
103
|
*
|
|
@@ -130,6 +134,14 @@ let webpackConfig = {
|
|
|
130
134
|
maxEntrypointSize: 500000
|
|
131
135
|
},
|
|
132
136
|
|
|
137
|
+
// Determine how modules are resolved.
|
|
138
|
+
// @see https://webpack.js.org/configuration/resolve/
|
|
139
|
+
resolve: {
|
|
140
|
+
// Allows extension to be leave off when importing.
|
|
141
|
+
// @see https://webpack.js.org/configuration/resolve/#resolveextensions
|
|
142
|
+
extensions: ['.js', '.jsx', '.ts', '.tsx', '.json', '...'],
|
|
143
|
+
},
|
|
144
|
+
|
|
133
145
|
// This option determine how different types of module within the project will be treated.
|
|
134
146
|
// @see https://webpack.js.org/configuration/module/
|
|
135
147
|
module:{
|
|
@@ -155,42 +167,48 @@ let webpackConfig = {
|
|
|
155
167
|
path.resolve(currentPath, 'helpers', 'string')
|
|
156
168
|
],
|
|
157
169
|
partialResolver: function(partial, callback){
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
callback(false, partialPath );
|
|
170
|
+
/**
|
|
171
|
+
* All template partials are loaded from the root sample directory
|
|
172
|
+
* if the file doesn't exist we fallback to our sample template partials
|
|
173
|
+
*/
|
|
174
|
+
let partialPath = path.join( process.cwd(), 'sample' );
|
|
175
|
+
let partialStructurePath = path.join( partialPath, 'structural' );
|
|
176
|
+
|
|
177
|
+
// template parameter specific partials
|
|
178
|
+
switch( partial ){
|
|
179
|
+
// header/footer is served from the /sample/structural/ directory
|
|
180
|
+
case 'footer':
|
|
181
|
+
case 'header':
|
|
182
|
+
partialPath = fs.existsSync(path.join( partialStructurePath, `/${partial}.html` )) ? path.join( partialStructurePath, `/${partial}.html` ) :
|
|
183
|
+
`./structural/${partial}.html`
|
|
184
|
+
|
|
185
|
+
break;
|
|
186
|
+
|
|
187
|
+
case 'content':
|
|
188
|
+
// content is served from /sample/index.html
|
|
189
|
+
partialPath = fs.existsSync(path.join( partialPath, '/index.html' )) ? path.join( partialPath, '/index.html' ) :
|
|
190
|
+
'./missing/content.html';
|
|
191
|
+
|
|
192
|
+
break;
|
|
193
|
+
|
|
194
|
+
// if not a template parameter we let the loader handle it
|
|
195
|
+
default:
|
|
196
|
+
partialPath = partial;
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
callback(false, partialPath );
|
|
189
200
|
}
|
|
190
201
|
}
|
|
202
|
+
},
|
|
203
|
+
// Handle `.tsx` and `.ts` files.
|
|
204
|
+
{
|
|
205
|
+
test: /\.tsx?$/,
|
|
206
|
+
use: 'ts-loader',
|
|
207
|
+
exclude: /node_modules/,
|
|
191
208
|
}
|
|
192
209
|
]
|
|
193
210
|
},
|
|
211
|
+
|
|
194
212
|
// WordPress already enqueues scripts and makes them available
|
|
195
213
|
// in global scope so those scripts don't need to be included on the bundle. For webpack
|
|
196
214
|
// to recognize those files, the global variable needs to be registered as externals.
|
|
@@ -203,11 +221,12 @@ let webpackConfig = {
|
|
|
203
221
|
lodash: 'lodash',
|
|
204
222
|
react: ['vendor', 'React'],
|
|
205
223
|
'react-dom': ['vendor', 'ReactDOM'],
|
|
206
|
-
|
|
224
|
+
|
|
207
225
|
// WordPress dependencies.
|
|
208
226
|
'@wordpress/hooks': ['vendor', 'wp', 'hooks'],
|
|
209
|
-
|
|
210
|
-
|
|
227
|
+
'@wordpress/i18n': ['vendor', 'wp', 'i18n'],
|
|
228
|
+
|
|
229
|
+
}
|
|
211
230
|
};
|
|
212
231
|
|
|
213
232
|
/**
|
|
@@ -217,7 +236,7 @@ if( 'serve' === webpackCommand ){
|
|
|
217
236
|
const appPath = process.cwd();
|
|
218
237
|
let template = flags.includes('--template') ? getArgVal('--template') : 'default';
|
|
219
238
|
let scheme = flags.includes('--scheme') ? getArgVal('--scheme') : 'oceanside';
|
|
220
|
-
|
|
239
|
+
|
|
221
240
|
// Dev Server is added
|
|
222
241
|
webpackConfig.devServer = {
|
|
223
242
|
devMiddleware: {
|
|
@@ -283,17 +302,17 @@ if( 'serve' === webpackCommand ){
|
|
|
283
302
|
// Page Template and additional plugins
|
|
284
303
|
webpackConfig.plugins.push(
|
|
285
304
|
new CAWebHTMLPlugin({
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
305
|
+
template,
|
|
306
|
+
templateParameters: {
|
|
307
|
+
scheme: 'false' !== scheme ? scheme : false
|
|
308
|
+
},
|
|
309
|
+
skipAssets: [
|
|
310
|
+
/.*-rtl.css/, // we skip the Right-to-Left Styles
|
|
311
|
+
/css-audit.*/, // we skip the CSSAudit Files
|
|
312
|
+
/a11y.*/, // we skip the A11y Files
|
|
313
|
+
/jshint.*/, // we skip the JSHint Files
|
|
314
|
+
/font-only.js/, // we skip the font-only Files
|
|
315
|
+
]
|
|
297
316
|
}),
|
|
298
317
|
new HtmlWebpackSkipAssetsPlugin(),
|
|
299
318
|
new HtmlWebpackLinkTypePlugin(),
|
|
@@ -326,10 +345,8 @@ if( 'serve' === webpackCommand ){
|
|
|
326
345
|
})
|
|
327
346
|
)
|
|
328
347
|
}
|
|
329
|
-
|
|
330
|
-
}
|
|
331
348
|
|
|
332
|
-
|
|
349
|
+
}
|
|
333
350
|
}
|
|
334
351
|
|
|
335
352
|
/**
|
|
@@ -343,7 +360,7 @@ if( mode === 'production' ){
|
|
|
343
360
|
// Output
|
|
344
361
|
webpackConfig.output.filename = '[name].min.js';
|
|
345
362
|
webpackConfig.output.chunkFilename = '[name].min.js?v=[chunkhash]';
|
|
346
|
-
|
|
363
|
+
|
|
347
364
|
// Plugins
|
|
348
365
|
webpackConfig.plugins.push(
|
|
349
366
|
new MiniCSSExtractPlugin( { filename: '[name].min.css' } ),
|
|
@@ -361,4 +378,5 @@ if( mode === 'production' ){
|
|
|
361
378
|
webpackConfig.plugins.push(
|
|
362
379
|
new RemoveEmptyScriptsPlugin()
|
|
363
380
|
);
|
|
364
|
-
|
|
381
|
+
|
|
382
|
+
export default webpackConfig;
|