-
-
Notifications
You must be signed in to change notification settings - Fork 403
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
Changes in Webpack make the suggested configurations throw an error (Adding imports-loader exports-loader) #4
Comments
9e1e057 this should do the effect. Thanks again @diego-caceres for your help! 👍 |
@diego-caceres could you copy paste your package.json here? I would love to update the dependencies in the article :)
|
Here you are @rwieruch and thanks for your tutorial
|
When we are adding Fetch and imports-loader and exports-loader to the project, the tutorial suggests to add the following configuration to 'webpack.config.js' :
plugins: [ new webpack.ProvidePlugin({ 'fetch': 'imports?this=>global!exports?global.fetch!whatwg-fetch' }) ]
But if you try to start the project you get an error. The problem is that WebPack's new version doesn't support to omit the '-loader' suffix.
The working configuration for me ended up like this:
plugins: [ new webpack.ProvidePlugin({ 'fetch': 'imports-loader?this=>global!exports-loader?global.fetch!whatwg-fetch' }) ]
The text was updated successfully, but these errors were encountered: