stylex
stylex copied to clipboard
It won't work without the CSS file generated by the css-loader
The problem
In Next.js, if you don't import any .css file, the styles generated by stylex will not be added to the stylesheet.
How to reproduce
Steps to reproduce:
- delete this line https://github.com/facebook/stylex/blob/c9b205750d835cba82b13ef5cdeaf30bbc683f70/apps/nextjs-example/app/layout.tsx#L10
- rebuild
- not working because not exists
.next/static/css
Expected behavior
Is any .css file necessary? Can it be omitted?
Environment (include versions). Did this work in previous versions?
https://github.com/facebook/stylex/blob/c9b205750d835cba82b13ef5cdeaf30bbc683f70/apps/nextjs-example/package.json