|
@@ -52,21 +52,21 @@ export default defineConfig({
|
|
|
},
|
|
},
|
|
|
'@icon-park/react'
|
|
'@icon-park/react'
|
|
|
]
|
|
]
|
|
|
- ]
|
|
|
|
|
- // externals: {
|
|
|
|
|
- // react: 'React',
|
|
|
|
|
- // 'react-dom': 'ReactDOM'
|
|
|
|
|
- // },
|
|
|
|
|
- // scripts:
|
|
|
|
|
- // process.env.NODE_ENV === 'development'
|
|
|
|
|
- // ? [
|
|
|
|
|
- // 'https://d2.smartcost.com.cn/cach/cld/react.development.js',
|
|
|
|
|
- // 'https://d2.smartcost.com.cn/cach/cld/react-dom.development.js'
|
|
|
|
|
- // ]
|
|
|
|
|
- // : [
|
|
|
|
|
- // 'https://d2.smartcost.com.cn/cach/cld/react.production.min.js',
|
|
|
|
|
- // 'https://d2.smartcost.com.cn/cach/cld/react-dom.production.min.js'
|
|
|
|
|
- // ],
|
|
|
|
|
|
|
+ ],
|
|
|
|
|
+ externals: {
|
|
|
|
|
+ react: 'React',
|
|
|
|
|
+ 'react-dom': 'ReactDOM'
|
|
|
|
|
+ },
|
|
|
|
|
+ headScripts:
|
|
|
|
|
+ process.env.NODE_ENV === 'development'
|
|
|
|
|
+ ? [
|
|
|
|
|
+ 'https://d2.smartcost.com.cn/cach/cld/react18.1.0/react.development.js',
|
|
|
|
|
+ 'https://d2.smartcost.com.cn/cach/cld/react18.1.0/react-dom.development.js'
|
|
|
|
|
+ ]
|
|
|
|
|
+ : [
|
|
|
|
|
+ 'https://d2.smartcost.com.cn/cach/cld/react18.1.0/react.production.min.js',
|
|
|
|
|
+ 'https://d2.smartcost.com.cn/cach/cld/react18.1.0/react-dom.production.min.js'
|
|
|
|
|
+ ],
|
|
|
// chainWebpack(config, { env }) {
|
|
// chainWebpack(config, { env }) {
|
|
|
// config.plugin('windicss').use('windicss-webpack-plugin')
|
|
// config.plugin('windicss').use('windicss-webpack-plugin')
|
|
|
// config.plugin('moment2dayjs').use('antd-dayjs-webpack-plugin')
|
|
// config.plugin('moment2dayjs').use('antd-dayjs-webpack-plugin')
|