Skip to content

React developer interface [WIP] #8861

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

Closed
wants to merge 9 commits into from

Conversation

bvaughn
Copy link
Contributor

@bvaughn bvaughn commented Jan 25, 2017

Continues from PR #7360.

First step toward repurposing the recently-added ReactFiberErrorLogger as a more generic ReactDevInterface. I am going to abandon this PR (for now) due to time constraints but I'd like to pick it back up in the future.

The basic idea is:

  • React provides a default, renderer-agnostic implementation that logs errors and warnings to the console. (This can help with things like Jest tests.)
  • Specific renderers (eg DOM, Native) can inject their own UI in order to promote awareness of warnings or to help developers better locate errors.
  • Application developers may choose to override renderer UI with their own hooks in order to log errors, direct users to report bugs, etc.

This PR is half-baked but it's here for posterity. 😄

UI treatment ideas for DOM

Team feedback

  • DOM and Native DX should be consistent. Doesn't have to look the same (web has more flexibility in terms of screen real estate and interactions) but should be familiar to devs and should expose the same basic information.
  • Warnings and errors may be associated; don't obscure warnings as they're often more helpful in spotting problems than errors.

@bvaughn bvaughn changed the title Yellow and red box hooks React developer interface [WIP] Jan 25, 2017
@bvaughn bvaughn closed this Jan 25, 2017
@bvaughn bvaughn mentioned this pull request Mar 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants