export default {
"entry": "src/index.js",
"env": {
"development": {
"extraBabelPlugins": [
"dva-hmr",
"transform-runtime",
["import", { "libraryName": "antd-mobile", "libraryDirectory": "lib", "style": "css" }]
]
},
"production": {
"extraBabelPlugins": [
"transform-runtime",
["import", { "libraryName": "antd-mobile", "libraryDirectory": "lib", "style": "css" }]
]
}
},
"svgSpriteLoaderDirs" : svgSpriteDirs
}
dva默认输出环境,是不是要修改`"publicPath"`选项'/'和'./'已试过,不行!
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
我也遇到过类似问题,我的解决方案是将 build 后的包放到 Apache 或者是 Ngnix 容器内。
已经解决了,问题出现在路由使用了browserhistory,把它改为hashHistory就可以了