STEVER February 2016

How to tell webpack not to compile CSS?

Can I make global exception not to apply loaders for CSS (or other file types).

Now I'm just getting an error:

...
ERROR in ./css/vendor/index.css
You may need an appropriate loader to handle this file type.
...

Answers


Edward February 2016

You can exclude it, add exclude option to css loader

loaders: [
  //
  {
    test: /\.css$/,
    loader: 'css-loader?minimize',
    exclude: /index\.css/
  }
]

Post Status

Asked in February 2016
Viewed 3,311 times
Voted 10
Answered 1 times

Search




Leave an answer