antd-management-fast-config 1.1.85 → 1.1.87

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.
Files changed (2) hide show
  1. package/package.json +11 -10
  2. package/src/configAssist.js +41 -21
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "antd-management-fast-config",
3
- "version": "1.1.85",
3
+ "version": "1.1.87",
4
4
  "description": "",
5
5
  "license": "ISC",
6
6
  "author": "",
@@ -57,22 +57,22 @@
57
57
  "@babel/preset-env": "^7.24.7",
58
58
  "@babel/preset-react": "^7.24.7",
59
59
  "@babel/runtime": "^7.24.7",
60
- "@changesets/cli": "^2.27.5",
60
+ "@changesets/cli": "^2.27.6",
61
61
  "@commitlint/cli": "^19.3.0",
62
62
  "@commitlint/config-conventional": "^19.2.2",
63
63
  "@commitlint/config-pnpm-scopes": "^19.1.0",
64
64
  "@pmmmwh/react-refresh-webpack-plugin": "^0.5.15",
65
65
  "@types/jest": "^29.5.12",
66
- "@types/node": "^20.14.2",
67
- "@typescript-eslint/parser": "^7.13.0",
68
- "@umijs/max": "^4.2.10",
66
+ "@types/node": "^20.14.8",
67
+ "@typescript-eslint/parser": "^7.13.1",
68
+ "@umijs/max": "^4.2.13",
69
69
  "babel-jest": "^29.7.0",
70
70
  "commitizen": "^4.3.0",
71
71
  "conventional-changelog-conventionalcommits": "^8.0.0",
72
72
  "cross-env": "^7.0.3",
73
73
  "cz-git": "^1.9.3",
74
74
  "docdash": "^2.0.2",
75
- "easy-soft-develop": "^2.1.190",
75
+ "easy-soft-develop": "^2.1.192",
76
76
  "eslint": "^8.57.0",
77
77
  "eslint-config-airbnb": "^19.0.4",
78
78
  "eslint-config-airbnb-typescript": "^18.0.0",
@@ -82,10 +82,10 @@
82
82
  "eslint-plugin-eslint-comments": "^3.2.0",
83
83
  "eslint-plugin-import": "^2.29.1",
84
84
  "eslint-plugin-jest": "^28.6.0",
85
- "eslint-plugin-jsx-a11y": "^6.8.0",
85
+ "eslint-plugin-jsx-a11y": "^6.9.0",
86
86
  "eslint-plugin-prettier": "^5.1.3",
87
87
  "eslint-plugin-promise": "^6.2.0",
88
- "eslint-plugin-react": "^7.34.2",
88
+ "eslint-plugin-react": "^7.34.3",
89
89
  "eslint-plugin-react-hooks": "^4.6.2",
90
90
  "eslint-plugin-simple-import-sort": "^12.1.0",
91
91
  "eslint-plugin-unicorn": "^52.0.0",
@@ -99,13 +99,14 @@
99
99
  "prettier-plugin-packagejson": "^2.5.0",
100
100
  "react": "^18.3.1",
101
101
  "react-dnd": "^16.0.1",
102
+ "react-refresh": "0.14.2",
102
103
  "rimraf": "^5.0.7",
103
104
  "stylelint": "^16.6.1",
104
105
  "stylelint-config-css-modules": "^4.4.0",
105
106
  "stylelint-config-prettier": "^9.0.5",
106
- "stylelint-config-standard": "^36.0.0",
107
+ "stylelint-config-standard": "^36.0.1",
107
108
  "stylelint-declaration-block-no-ignored-properties": "^2.8.0",
108
109
  "stylelint-order": "^6.0.4",
109
- "umi": "^4.2.10"
110
+ "umi": "^4.2.13"
110
111
  }
111
112
  }
@@ -12,32 +12,51 @@ function checkDevelopment() {
12
12
  function buildConfig({ packageJson: packageImport, config = {} }) {
13
13
  const deps = packageImport.dependencies;
14
14
 
15
- let mfsu = {};
16
- const shared = {};
15
+ let { mfsu } = {
16
+ mfsu: false,
17
+ ...config,
18
+ };
17
19
 
18
- if (deps) {
19
- if (deps['react']) {
20
- shared.react = {
21
- singleton: true,
22
- eager: true,
23
- requiredVersion: deps['react'],
24
- };
25
- }
20
+ if (checkDevelopment()) {
21
+ if (mfsu !== null && typeof mfsu === 'object') {
22
+ const shared = {};
26
23
 
27
- if (deps['react-dom']) {
28
- shared['react-dom'] = {
29
- singleton: true,
30
- eager: true,
31
- requiredVersion: deps['react-dom'],
32
- };
33
- }
24
+ if (deps) {
25
+ if (deps['react']) {
26
+ shared.react = {
27
+ singleton: true,
28
+ eager: true,
29
+ requiredVersion: deps['react'],
30
+ };
31
+ }
32
+
33
+ if (deps['react-dom']) {
34
+ shared['react-dom'] = {
35
+ singleton: true,
36
+ eager: true,
37
+ requiredVersion: deps['react-dom'],
38
+ };
39
+ }
34
40
 
35
- mfsu.remotes = [];
36
- mfsu.shared = shared;
41
+ mfsu.shared = {
42
+ ...mfsu.shared,
43
+ ...shared,
44
+ };
45
+ }
46
+ } else {
47
+ mfsu = false;
48
+ }
49
+ } else {
50
+ mfsu = false;
37
51
  }
38
52
 
39
- const mergeConfig = {
53
+ const configAdjust = {
54
+ ...config,
40
55
  mfsu,
56
+ };
57
+
58
+ const mergeConfig = {
59
+ mfsu: false,
41
60
  hash: true,
42
61
  antd: {},
43
62
  access: {},
@@ -53,7 +72,8 @@ function buildConfig({ packageJson: packageImport, config = {} }) {
53
72
  baseNavigator: true,
54
73
  },
55
74
  layout: {},
56
- ...config,
75
+ esbuildMinifyIIFE: true,
76
+ ...configAdjust,
57
77
  };
58
78
 
59
79
  delete mergeConfig.dva;