Skip to content

Build fails when bundling css, Error: "extract-text-webpack-plugin" loader is used without the corresponding plugin #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
au-re opened this issue Oct 8, 2018 · 0 comments

Comments

@au-re
Copy link

au-re commented Oct 8, 2018

I get the following error when running react-app-rewired build --library:

/src/components/Button/Button.css
Module build failed: Error: "extract-text-webpack-plugin" loader is used without the corresponding plugin, refer to https://github.com/webpack/extract-text-webpack-plugin for the usage example

The css is imported as: import "./Button.css".

Replacing

config.plugins=[ ]

with

config.plugins = [
 new ExtractTextPlugin("styles.css"),
];

seems to solve the problem..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant