react-strict-dom
react-strict-dom copied to clipboard
Add react-strict-dom/postcss-plugin based on @stylexjs/postcss-plugin
TODO
- [ ] Wait for https://github.com/facebook/stylex/pull/1063 and https://github.com/facebook/stylex/pull/1065 to be published on npm and update
@stylexjs/package dependencies - [ ] Test changes in the examples app
Why
https://github.com/facebook/react-strict-dom/issues/281#issuecomment-2712591645
This PR upstreams postcss-react-strict-dom to the official repo to make it easier for maintainers to make changes.
I added RSD compatibility to @stylexjs/postcss-plugin in this PR, so this adds react-strict-dom/postcss-plugin that re-exports the StyleX PostCSS Plugin with the required configuration for RSD consumers.
How
- Added PostCSS Plugin to
packages/react-strict-dom/postcss/plugin.js - Export the plugin as
react-strict-dom/postcss-pluginin package.json - Updated
apps/examplesto use the official plugin and removed postcss-react-strict-dom dependency - Updated docs to use the official plugin
Test Plan
- [ ] Run
cd apps/example && npm run dev:webboth from the original repo and this branch and compare side-by-side to make sure output matches