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

'Warning: ' messages should use console.warn() #6414

Closed
danbernardi opened this issue Apr 5, 2016 · 1 comment
Closed

'Warning: ' messages should use console.warn() #6414

danbernardi opened this issue Apr 5, 2016 · 1 comment

Comments

@danbernardi
Copy link

Currently they use console.error(), which overestimates their severity and causes devs to react more strongly than the message might imply.

Example:

warning.js:45 
Warning: Failed propType: Invalid prop `things` of type `array` supplied to `Item`, expected `object`. Check the render method of `Connect(Item)`.
@zpao
Copy link
Member

zpao commented Apr 5, 2016

Thanks for the feedback but this is intentional. console.error provides good stack traces and our treatment of warnings is that they should be fixed before they are committed and shipped. With maybe 1 exception, I think they should all be fixable.

One of the things we're working towards is a better way to manage these so that you can silence specific warnings or types of warnings without having to fork React. You can track that in the umbrella issue - #5306

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