@enact/cli 6.1.2 → 6.1.3
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 +4 -0
- package/commands/pack.js +4 -1
- package/config/webpack.config.js +14 -2
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/commands/pack.js
CHANGED
|
@@ -58,6 +58,7 @@ function displayHelp() {
|
|
|
58
58
|
Private Options:
|
|
59
59
|
--entry Specify an override entrypoint
|
|
60
60
|
--no-minify Will skip minification during production build
|
|
61
|
+
--no-split-css Will not split CSS into separate files
|
|
61
62
|
--framework Builds the @enact/*, react, and react-dom into an external framework
|
|
62
63
|
--externals Specify a local directory path to the standalone external framework
|
|
63
64
|
--externals-public Remote public path to the external framework for use injecting into HTML
|
|
@@ -258,6 +259,7 @@ function api(opts = {}) {
|
|
|
258
259
|
opts['content-hash'],
|
|
259
260
|
opts.isomorphic,
|
|
260
261
|
!opts.animation,
|
|
262
|
+
!opts['split-css'],
|
|
261
263
|
opts.framework,
|
|
262
264
|
opts['ilib-additional-path']
|
|
263
265
|
);
|
|
@@ -289,6 +291,7 @@ function cli(args) {
|
|
|
289
291
|
'content-hash',
|
|
290
292
|
'custom-skin',
|
|
291
293
|
'minify',
|
|
294
|
+
'split-css',
|
|
292
295
|
'framework',
|
|
293
296
|
'externals-corejs',
|
|
294
297
|
'stats',
|
|
@@ -301,7 +304,7 @@ function cli(args) {
|
|
|
301
304
|
'help'
|
|
302
305
|
],
|
|
303
306
|
string: ['externals', 'externals-public', 'locales', 'entry', 'ilib-additional-path', 'output', 'meta'],
|
|
304
|
-
default: {minify: true, animation: true},
|
|
307
|
+
default: {minify: true, 'split-css': true, animation: true},
|
|
305
308
|
alias: {
|
|
306
309
|
o: 'output',
|
|
307
310
|
p: 'production',
|
package/config/webpack.config.js
CHANGED
|
@@ -45,6 +45,7 @@ module.exports = function (
|
|
|
45
45
|
contentHash = false,
|
|
46
46
|
isomorphic = false,
|
|
47
47
|
noAnimation = false,
|
|
48
|
+
noSplitCSS = false,
|
|
48
49
|
framework = false,
|
|
49
50
|
ilibAdditionalResourcesPath
|
|
50
51
|
) {
|
|
@@ -451,7 +452,17 @@ module.exports = function (
|
|
|
451
452
|
parallel: true
|
|
452
453
|
}),
|
|
453
454
|
new CssMinimizerPlugin()
|
|
454
|
-
]
|
|
455
|
+
],
|
|
456
|
+
splitChunks: noSplitCSS && {
|
|
457
|
+
cacheGroups: {
|
|
458
|
+
styles: {
|
|
459
|
+
name: 'main',
|
|
460
|
+
type: 'css/mini-extract',
|
|
461
|
+
chunks: 'all',
|
|
462
|
+
enforce: true
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
}
|
|
455
466
|
},
|
|
456
467
|
plugins: [
|
|
457
468
|
// Generates an `index.html` file with the js and css tags injected.
|
|
@@ -495,7 +506,8 @@ module.exports = function (
|
|
|
495
506
|
!process.env.INLINE_STYLES &&
|
|
496
507
|
new MiniCssExtractPlugin({
|
|
497
508
|
filename: contentHash ? '[name].[contenthash].css' : '[name].css',
|
|
498
|
-
chunkFilename: contentHash ? 'chunk.[name].[contenthash].css' : 'chunk.[name].css'
|
|
509
|
+
chunkFilename: contentHash ? 'chunk.[name].[contenthash].css' : 'chunk.[name].css',
|
|
510
|
+
ignoreOrder: noSplitCSS
|
|
499
511
|
}),
|
|
500
512
|
// Webpack5 removed node polyfills but we need this to run screenshot tests
|
|
501
513
|
new NodePolyfillPlugin(),
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@enact/cli",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.3",
|
|
4
4
|
"lockfileVersion": 2,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@enact/cli",
|
|
9
|
-
"version": "6.1.
|
|
9
|
+
"version": "6.1.3",
|
|
10
10
|
"license": "Apache-2.0",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@babel/plugin-transform-modules-commonjs": "^7.23.3",
|