@mxmweb/zui 1.0.19 → 1.1.1

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/dist/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "style": "assets/style.css",
6
6
  "types": "lib_enter.d.ts",
7
7
  "private": false,
8
- "version": "1.1.0",
8
+ "version": "1.1.1",
9
9
  "author": "hanfeng_Zhang",
10
10
  "type": "module",
11
11
  "scripts": {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mxmweb/zui",
3
3
  "author": "hanfeng_Zhang",
4
- "version": "1.0.19",
4
+ "version": "1.1.1",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/lib_enter.d.ts",
package/vite.config.ts CHANGED
@@ -108,6 +108,19 @@ export default ({ mode }: { mode: string }) => {
108
108
  },
109
109
  rollupOptions: {
110
110
  external: (id) => {
111
+ // 在开发环境中,不外部化 @mxmweb 包,让它们能够正确解析
112
+ if (mode === 'development') {
113
+ return [
114
+ 'react',
115
+ 'react-dom',
116
+ 'styled-components',
117
+ 'animejs',
118
+ 'antd',
119
+ 'lucide-react',
120
+ ].some(pkg => id === pkg || id.startsWith(`${pkg}/`));
121
+ }
122
+
123
+ // 在生产构建中,外部化所有 @mxmweb 包
111
124
  return [
112
125
  'react',
113
126
  'react-dom',