design-system icon indicating copy to clipboard operation
design-system copied to clipboard

Feature/add ssr for next projects

Open glennverschooren opened this issue 4 months ago • 4 comments

Add SSR Support for Next.js - Hydration Issues

Description:

This PR introduces a draft version of server-side rendering (SSR) support for Next.js in the Baloise design system. While I've made progress in implementing SSR, there are still a few issues I couldn't resolve myself.

Current Issues:

Next.js is throwing warnings and errors during the hydration process. The primary issue is that the HTML generated on the server does not match the HTML on the client, leading to hydration failures. As a result, the client-side app is not able to hydrate the server-rendered content correctly, causing the mismatch. Since I’ve been unable to fully fix these issues, I'm opening this PR so you can review the implementation and provide guidance on resolving these problems.

Steps Taken So Far:

Integrated SSR within the Next.js framework. Attempted to address hydration discrepancies but ran into persistent errors. I would appreciate any insights or suggestions to help resolve these issues and improve SSR support for the design system.

glennverschooren avatar Oct 07 '24 13:10 glennverschooren