Styled-jsx: Flash of unstyled content with recent v3.2.2 upgrade.

Created on 7 Sep 2019  路  3Comments  路  Source: vercel/styled-jsx

Do you want to request a feature or report a bug?

A bug 馃悰 .

What is the current behavior?

After upgrading styled-jsx from 3.2.1 to 3.2.2 we noticed our entire web app flashes unstyled content in production (hosted with zeit). However, this is not reproducible within a development environment (now dev).

Environment (include versions)

  • OS: OSX 10.14.6
  • Browser: Firefox 68.0.2
  • styled-jsx (version): 3.2.2

Did this work in previous versions?

Yes

Most helpful comment

Specifically, we had [email protected] in our package.json and next/[email protected]. Having both versions was causing unstyled content to flash.

(@maxchehab and I are on the same team)

All 3 comments

@maxchehab can you provide a test case? Maybe a minimal Next.js app that I can clone and try out

@giuseppeg Sorry for the lag.

We resolved this by removing styled-jsx as a dependency for our project.

It seems since we are using NextJS (which depends on styled-jsx), including styled-jsx was causing conflicts with our css (maybe with generated class names?).

Again, sorry for not responding quicker.

Specifically, we had [email protected] in our package.json and next/[email protected]. Having both versions was causing unstyled content to flash.

(@maxchehab and I are on the same team)

Was this page helpful?
0 / 5 - 0 ratings