Development build produces styled components like expected, while the production build doesn’t style anything at all, although there are class names added.
I tried both using the css-prop transform preset and the plugin & preset combo like https://emotion.sh/docs/css-prop##babel-preset suggested, but both produce nothing.
The dev build on the other hand is okay with just the preset.
The only Emotion things that I can see in the final build are a
<style data-emotion="css" data-s=""></style>
tag and the css classes, also there are a lot of emotions in the source files, so something did build, its just that that something is probably not appending the style tags into the header ?
git clone https://github.com/Twiggeh/emotion-no-prod-styles
cd emotion-no-prod-styles/client/ && yarn install && yarn run build
cd ../server && yarn install && node ./src/app.js
To get styles outputted for when I use the development build.