dillon1000/react

Commit

Warning system refactoring (part 1) (#16799)

* Rename lowPriorityWarning to lowPriorityWarningWithoutStack

This maintains parity with the other warning-like functions.

* Duplicate the toWarnDev tests to test toLowPriorityWarnDev

* Make a lowPriorityWarning version of warning.js

* Extract both variants in print-warning

Avoids parsing lowPriorityWarning.js itself as the way it forwards the
call to lowPriorityWarningWithoutStack is not analyzable.
Browse files
Changed paths13 files
First-parent comparison
M packages/react-dom/src/client/ReactDOM.js ModifiedM packages/react-dom/src/server/ReactPartialRenderer.js ModifiedM packages/react-dom/src/test-utils/ReactTestUtils.js ModifiedM packages/react-is/src/ReactIs.js ModifiedM packages/react-reconciler/src/ReactStrictModeWarnings.js ModifiedM packages/react/src/ReactBaseClasses.js ModifiedM packages/react/src/ReactElementValidator.js ModifiedR packages/shared/forks/lowPriorityWarning.www.js →packages/shared/forks/lowPriorityWarningWithoutStack.www.js RenamedM packages/shared/lowPriorityWarning.js ModifiedA packages/shared/lowPriorityWarningWithoutStack.js AddedM scripts/jest/matchers/__tests__/toWarnDev-test.js ModifiedM scripts/print-warnings/print-warnings.js ModifiedM scripts/rollup/forks.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…