Fixing differences between prod and dev build (Next.js) πŸ™ƒ

Next.js seems to apply CSS modules differently on a route transition in production, which makes it difficult to use together with framer-motion πŸ€·β€β™‚οΈ Switched to styled-jsx

The way NextJS applies CSS puzzles me a bit

0 Likes
Maximilian Torggler Author

I just realized framer-motion doesn't play well with styled-jsx πŸ€¦β€β™‚οΈ

0 Likes
Maximilian Torggler Author

Yea there seems to be happening too much performance "magic" under the hood, and it gets even funnier when those things just happen in production. It suddenly occurred when updating to version 9.5.5, before it worked fine. What a pitty, I really like my CSS in CSS files

0 Likes

Please sign in to leave a comment.