-
|
I have an function that uses random number generation (currently
Is there a solution that allows me to avoid these drawbacks i.e. not make extra requests to the server but also not render the page twice with different values on initial load? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
|
if anyone stumbles across this question in 2026: these days sveltekit has whatever value is generated/returned in SSR will carry over into hydration, ensuring a hydration match and avoiding said unpleasent change as JS kicks in |
Beta Was this translation helpful? Give feedback.
if anyone stumbles across this question in 2026: these days sveltekit has
hydratable(), which may solve this kind of problem:whatever value is generated/returned in SSR will carry over into hydration, ensuring a hydration match and avoiding said unpleasent change as JS kicks in