dillon1000/react

Commit

Log all Fiber errors w/ component stack (#8756)

A new module has been added (ReactFiberErrorLogger). This logs error information (call stack and component stack) to the console to make errors easier to debug. It also prompts users to use error boundaries if they are not already using them.

In the future, perhaps this will be injectable, enabling users to provide their own handler for custom processing/logging. For the time being, this should help with issues like this / #2461.
Browse files
Changed paths5 files
First-parent comparison
M scripts/fiber/tests-passing.txt ModifiedM scripts/jest/test-framework-setup.js ModifiedA src/renderers/shared/fiber/ReactFiberErrorLogger.js AddedM src/renderers/shared/fiber/ReactFiberScheduler.js ModifiedM src/renderers/shared/fiber/__tests__/ReactIncrementalErrorHandling-test.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…