Closed haoyinag closed 2 years ago
fastRefresh和mfsu貌似有一些冲突,你可以尝试关掉这两个再试试,个人经验
你好解决了吗,我的使用了mfsu也是热更新失效,编译一样缓慢 ` import { defineConfig } from 'umi' import defaultSettings from './defaultSettings' import proxy from './proxy' import routes from './routes'
const { REACT_APP_ENV } = process.env
export default defineConfig({ publicPath: './', history: { type: 'hash', }, hash: true, antd: {}, dva: { hmr: true, }, layout: { locale: true, siderWidth: 208, ...defaultSettings, }, locale: { default: 'zh-CN', antd: true, baseNavigator: true, }, dynamicImport: { loading: '@ant-design/pro-layout/es/PageLoading', }, targets: { ie: 11, }, routes, theme: { 'primary-color': defaultSettings.primaryColor, }, define: { CIONFONT_URL: '//at.alicdn.com/t/font_2880658_vdspkak56e.js', }, esbuild: {}, title: false, ignoreMomentLocale: true, proxy: proxy[REACT_APP_ENV || 'dev'], manifest: { basePath: '/', }, // Fast Refresh 热更新 fastRefresh: {}, nodeModulesTransform: { type: 'none' }, // mfsu: {}, // webpack5: {}, exportStatic: {}, }) `
如题
综上所述带来不大友好的开发体验。 不确定是不是我配置问题
配置