dillon1000/react

Commit

Use hack to support isMounted without stateful module

This hack allow us to get rid of the stateful module ReactLifeCycle since
we can infer the value of isMounted even without it. This gets rid of
the try/catch which is deopting all mountComponent calls.

As a next step we could deprecate isMounted completely and avoid stateful
APIs. Since it can be easily simulated if you truly need it.
Browse files
Changed paths4 files
First-parent comparison
M src/renderers/shared/reconciler/ReactCompositeComponent.js ModifiedD src/renderers/shared/reconciler/ReactLifeCycle.js DeletedM src/renderers/shared/reconciler/ReactUpdateQueue.js ModifiedM src/renderers/shared/reconciler/__tests__/ReactComponentLifeCycle-test.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…