@umijs/mfsu 4.0.33 → 4.0.34

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.
@@ -67,8 +67,11 @@ function checkMatch({
67
67
  const remoteName = opts.remoteName || "mf";
68
68
  value = value.replace(/^@fs\//, "/");
69
69
  const unMatchLibsRegex = genUnMatchLibsRegex(opts.unMatchLibs);
70
- if ((unMatchLibsRegex == null ? void 0 : unMatchLibsRegex.test(value)) || value.includes("client/client/client.js") || value.startsWith(`${remoteName}/`) || (0, import_utils.winPath)(value).includes("babel/svgr-webpack") || value.startsWith("!!") || (0, import_isExternals.isExternals)({ value, externals: opts.externals }) || value.startsWith(".")) {
70
+ const mfPathInitial = `${remoteName}/`;
71
+ if ((unMatchLibsRegex == null ? void 0 : unMatchLibsRegex.test(value)) || value.includes("client/client/client.js") || (0, import_utils.winPath)(value).includes("babel/svgr-webpack") || value.startsWith("!!") || (0, import_isExternals.isExternals)({ value, externals: opts.externals }) || value.startsWith(".")) {
71
72
  isMatch = false;
73
+ } else if (value.startsWith(mfPathInitial)) {
74
+ isMatch = true;
72
75
  } else if ((0, import_path.isAbsolute)(value)) {
73
76
  isMatch = RE_NODE_MODULES.test(value) || isUmiLocalDev(value);
74
77
  } else {
@@ -94,7 +97,12 @@ function checkMatch({
94
97
  isMatch = !!(opts.exportAllMembers && value in opts.exportAllMembers);
95
98
  }
96
99
  if (isMatch) {
97
- replaceValue = `${remoteName}/${(0, import_utils.winPath)(value)}`;
100
+ if (value.startsWith(mfPathInitial)) {
101
+ replaceValue = value;
102
+ value = value.replace(mfPathInitial, "");
103
+ } else {
104
+ replaceValue = `${remoteName}/${(0, import_utils.winPath)(value)}`;
105
+ }
98
106
  }
99
107
  const file = (path == null ? void 0 : path.hub.file.opts.filename) || filename;
100
108
  (_a = opts.onTransformDeps) == null ? void 0 : _a.call(opts, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@umijs/mfsu",
3
- "version": "4.0.33",
3
+ "version": "4.0.34",
4
4
  "description": "@umijs/mfsu",
5
5
  "homepage": "https://github.com/umijs/umi/tree/master/packages/mfsu#readme",
6
6
  "bugs": "https://github.com/umijs/umi/issues",
@@ -23,9 +23,9 @@
23
23
  "test": "umi-scripts jest-turbo"
24
24
  },
25
25
  "dependencies": {
26
- "@umijs/bundler-esbuild": "4.0.33",
27
- "@umijs/bundler-utils": "4.0.33",
28
- "@umijs/utils": "4.0.33",
26
+ "@umijs/bundler-esbuild": "4.0.34",
27
+ "@umijs/bundler-utils": "4.0.34",
28
+ "@umijs/utils": "4.0.34",
29
29
  "enhanced-resolve": "5.9.3",
30
30
  "is-equal": "^1.6.4"
31
31
  },