zuiidea / antd-admin

An excellent front-end solution for enterprise applications built upon Ant Design and UmiJS

Home Page:https://antd-admin.zuiidea.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

webpack.config.js的ClassnameHash没有进循环里面去

yangbin1994 opened this issue · comments

commented
  if (env === 'production' && webpackConfig.module) {
    // ClassnameHash
    webpackConfig.module.rules.map((item) => {
      if (item.use && item.use[0] === 'style') {
        console.log(item)
        return item.use.map((iitem) => {
          if (iitem && iitem.loader === 'css') {
            iitem.options.localIdentName = '[hash:base64:5]'
          }
          return iitem
        })
      }
      return item
    })
  }

后面调整过,ClassnameHash应该是可以了