javascript - Trying to Bundle CSS with ExtractTextPlugin -
i'm trying bundle css 1 file webpack. i've got working scripts.but error css:
module not found: error: can't resolve 'circle.css' in 'c:\projects\tag-validator-front2\src\css'.
here's webpack config:
var extracttextplugin = require('extract-text-webpack-plugin'); module.exports = { entry: ["./src/ts/main.js","./src/css/css.js"], module: { loaders: [ { test: /\.jsx?$/, loader: "babel-loader" }, { test: /\.css/, loader: extracttextplugin.extract("css") } ] }, plugins: [ new extracttextplugin("styles.css") ], output: { filename: "public/bundle.js" } }
main.js scripts , working, css.js isn't. here's css.js:
"use strict"; import circlestyles 'circle.css';
i'm importing 1 right until working, of css in directory , in sub folders.
try use relative import path: import './circle.css';
Comments
Post a Comment