Skip to content
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

remove warnings #341

Closed
paOol opened this issue Sep 7, 2017 · 3 comments
Closed

remove warnings #341

paOol opened this issue Sep 7, 2017 · 3 comments

Comments

@paOol
Copy link

paOol commented Sep 7, 2017

 WARNING  Failed to compile with 13 warnings
./src/components/kraken/kraken.js
  Line 1:  'Component' is defined but never used  no-unused-vars
  Line 2:  'axios' is defined but never used      no-unused-vars

where do you disable these warning messages?

@paOol
Copy link
Author

paOol commented Sep 7, 2017

I commented out lines 61-66 in \node_modules\razzle-dev-utils\FriendlyErrorsPlugin.js

but there is probably a better way to do this.

@jariz jariz closed this as completed Sep 8, 2017
@jariz
Copy link
Collaborator

jariz commented Sep 8, 2017

You'll have to add a razzle.config.js to the root of your project that modifies the webpack config to remove the eslint-loader.
Untested, but will probably work:

module.exports = {
  modify: (config, {target, dev}, webpack) => {
    // remove the first loader (eslint-loader)
    config.module.rules.shift();
  
    return config
  }
}

@jariz
Copy link
Collaborator

jariz commented Sep 8, 2017

Btw the "Failed to compile" part of the message is wrong, it actually compiles fine, so apart from them simply showing up, the warnings don't really have any downside, so I'm not 100% sure why you'd want to do this.

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

2 participants