-
Notifications
You must be signed in to change notification settings - Fork 49.3k
Open
Labels
Component: Core UtilitiesReact Core TeamOpened by a member of the React Core TeamOpened by a member of the React Core TeamType: Enhancement
Description
We have a queue for state transitions. There is a natural place for a new Error()
stack frame to be stored there.
We could use this information to work our way back from errors to show information about which setState
call was the source of the error.
Because of batching, it is not always possible to make the correct attribution. It could be one of several possible sources.
(Specifically I'd like to use this in Fiber when the starvation protection kicks in. We can show which state transition was kept getting deferred due to higher priority work.)
threepointone
Metadata
Metadata
Assignees
Labels
Component: Core UtilitiesReact Core TeamOpened by a member of the React Core TeamOpened by a member of the React Core TeamType: Enhancement