dillon1000/react

Commit

[Suspense] Use style.setProperty to set display (#15882)

Follow up to #15861.

Turns out you can't set `!important` using a normal property assignment.
You have to use `style.setProperty`.

Maybe Andrew *should* just learn CSS.

IE9 doesn't support `style.setProperty` so we'll fall back to setting
`display: none` without `important`, like we did before #15861 Our
advice for apps that need to support IE9 will be to avoid using
`!important`. Which seems like good advice in general, but IANACSSE.

Tested on FB and using our Suspense DOM fixture.
Browse files
Changed paths3 files
First-parent comparison
M packages/react-dom/src/__tests__/ReactDOMSuspensePlaceholder-test.js ModifiedM packages/react-dom/src/client/ReactDOMHostConfig.js ModifiedM packages/react-fresh/src/__tests__/ReactFresh-test.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…