xiubug / react-antd

基于react + redux + immutable + less + ES6/7 + webpack2.0 + fetch + react-router + antd实现的SPA后台管理系统模板

Home Page:http://antd.sosout.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

yarn run dev 报错

Kennytian opened this issue · comments

commented

yarn run dev

node_modules/extract-text-webpack-plugin/index.js:187
throw new Error("Breaking change: extract now only takes a single argument. Either an options " +
^

Error: Breaking change: extract now only takes a single argument. Either an options object or the loader(s).
Example: if your old code looked like this:
ExtractTextPlugin.extract('style-loader', 'css-loader')

You would change it to:
ExtractTextPlugin.extract({ fallback: 'style-loader', use: 'css-loader' })

真是抱歉,已急速修复完毕。导致以上的原因:webpack版本升级,忘记把npm run dev (正常编译模式,注意:index.html里必须手动引用app.css,{linkHtml},否则没有样式)的代码迭代了,强烈推荐用 npm run hot (热替换编译模式,注意:热替换模式下index.html里去掉引用app.css)。分两个模式目的告知如何实现热替换