Create-react-app: Show a transparent overlay with development warnings

Created on 23 Mar 2017  路  10Comments  路  Source: facebook/create-react-app

As proposed here, maybe we should have a transparent "warning overlay" which is dismiss-able.

proposal

Most helpful comment

We have exposed frames for react 16 warnings in https://github.com/facebook/react/pull/13242 and react-error-overlay can now take advantage of them in a future rewrite

All 10 comments

It'll show in the website the user is developing @Timer ? If yes, a full screen overlay shows every time when there are warnings ?

Warnings won't take over the screen like an error.

The idea is to make less-intrusive version of the crash overlay which appears for runtime warnings, and maybe compile warnings.

Basically, only when in development mode, there would be a small pop-up on screen (which is unobtrusive). Hovering it would display more context and clicking would "pop" it into a full screen overlay like crash overlay.

Think toastr.

Cool, Okay 馃憤

I would hold off implementing this because we might want to build something like this into React itself. @bvaughn experimented with it. It鈥檚 going to be confusing if these efforts are not aligned.

@bvaughn @gaearon any update on the warnings? I've got my hands free and build this for CRA's lint warning.

jul-13-2017 03-20-34

Nothing yet on our end, @viankakrisna, although I plan to pick it back up soon.
Your overlay looks nice! 馃槃

Thanks! sent a PR 馃槃 IIRC the React ones gonna be about React's own warning right?

Depends. We haven't decided yet what the error/warning API will look like for 16. Would be nice if CRA (and maybe other 3rd party libs) could piggy-back on React's warning system.

Ok, I'll leave it to the maintainers about my overlay then. Excited to see how it will be implemented though :)

We have exposed frames for react 16 warnings in https://github.com/facebook/react/pull/13242 and react-error-overlay can now take advantage of them in a future rewrite

Was this page helpful?
0 / 5 - 0 ratings

Related issues

fson picture fson  路  3Comments

wereHamster picture wereHamster  路  3Comments

ap13p picture ap13p  路  3Comments

alleroux picture alleroux  路  3Comments

jnachtigall picture jnachtigall  路  3Comments