react-grid-system icon indicating copy to clipboard operation
react-grid-system copied to clipboard

SSR / Styled Components

Open gregorskii opened this issue 5 years ago • 2 comments

A similar question has been asked, but I am getting flashes where the grid is temporarily unstyled at load in a Next application.

The site is styled with Styled Components for generic styling, and that works correctly at page load due to the configuration here https://github.com/zeit/next.js/blob/canary/examples/with-styled-components/pages/_document.js.

However the <Containers/> in our app are flashing unstyled at load.

Forgive me if this is just me misunderstanding how SSR works in this case. But I thought it should style when the containers are loaded from a page in Next.

Thanks in advance.

gregorskii avatar Sep 19 '19 23:09 gregorskii

Can you validate whether this is still the case with the latest version (^6.4.0)? This version contains some improvements wrt. SSR.

gerbenmeyer avatar May 10 '20 09:05 gerbenmeyer

I confirm this is still the case, even with de latest;

sephi-dev avatar May 03 '21 22:05 sephi-dev