@shuvi/toolpack 2.0.0-dev.16 → 2.0.0-dev.17
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.
|
@@ -154,28 +154,11 @@ function createBrowserRspackChain(options) {
|
|
|
154
154
|
return (module.size() > BIG_LIBRARY_THRESHOLD &&
|
|
155
155
|
helpers_rspack_1.NODE_MODULES_REGEXP.test(module.nameForCondition() || ''));
|
|
156
156
|
},
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
// libIdent?: Function;
|
|
163
|
-
// updateHash: (hash: crypto.Hash) => void;
|
|
164
|
-
// }): string {
|
|
165
|
-
// const hash = crypto.createHash('sha1');
|
|
166
|
-
// if (module.type === `css/mini-extract`) {
|
|
167
|
-
// module.updateHash(hash);
|
|
168
|
-
// } else {
|
|
169
|
-
// if (!module.libIdent) {
|
|
170
|
-
// throw new Error(
|
|
171
|
-
// `Encountered unknown module type: ${module.type}. Please open an issue.`
|
|
172
|
-
// );
|
|
173
|
-
// }
|
|
174
|
-
// hash.update(module.libIdent({ context: options.projectRoot }));
|
|
175
|
-
// }
|
|
176
|
-
// return hash.digest('hex').substring(0, 8);
|
|
177
|
-
// },
|
|
178
|
-
name: 'lib',
|
|
157
|
+
name(module) {
|
|
158
|
+
const hash = crypto.createHash('sha1');
|
|
159
|
+
hash.update(module.identifier());
|
|
160
|
+
return hash.digest('hex').substring(0, 8);
|
|
161
|
+
},
|
|
179
162
|
filename: (0, helpers_rspack_1.commonChunkFilename)({ dev: false }),
|
|
180
163
|
priority: 30,
|
|
181
164
|
minChunks: 1,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shuvi/toolpack",
|
|
3
|
-
"version": "2.0.0-dev.
|
|
3
|
+
"version": "2.0.0-dev.17",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/shuvijs/shuvi.git",
|
|
@@ -36,9 +36,9 @@
|
|
|
36
36
|
"@rspack/cli": "^1.4.2",
|
|
37
37
|
"@rspack/core": "^1.4.2",
|
|
38
38
|
"@rspack/plugin-html": "^0.5.8",
|
|
39
|
-
"@shuvi/compiler": "2.0.0-dev.
|
|
40
|
-
"@shuvi/shared": "2.0.0-dev.
|
|
41
|
-
"@shuvi/utils": "2.0.0-dev.
|
|
39
|
+
"@shuvi/compiler": "2.0.0-dev.17",
|
|
40
|
+
"@shuvi/shared": "2.0.0-dev.17",
|
|
41
|
+
"@shuvi/utils": "2.0.0-dev.17",
|
|
42
42
|
"@swc/helpers": "0.4.3",
|
|
43
43
|
"babel-loader": "8.2.2",
|
|
44
44
|
"babel-plugin-syntax-jsx": "6.18.0",
|