webpack

css-module https://zhuanlan.zhihu.com/p/20495964

使用css-loader,需要在plugins添加

new ExtractTextPluginStyle('style.css', { allChunks: true }),

在loaders里面添加

 {
    test: /\.css$/, 
    loader: ExtractTextPlugin.extract('style-loader', 'css?modules&localIdentName=[name]__[local]-[hash:base64:5]')
}

  


posted on 2016-05-27 16:36  reacTime  阅读(129)  评论(0)    收藏  举报