Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SSR - Hydration text mismatch #209

Open
imcm7 opened this issue Sep 12, 2023 · 2 comments
Open

SSR - Hydration text mismatch #209

imcm7 opened this issue Sep 12, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@imcm7
Copy link

imcm7 commented Sep 12, 2023

On server it not read color because color is stored in local storage and not cookie

@imcm7 imcm7 added the bug Something isn't working label Sep 12, 2023
@RamaHerbin
Copy link

I've got the same issue here
Screenshot 2023-10-16 at 14 53 42

@Kolobok12309
Copy link

You can try use ClientOnly for components that use theme variable like this

<div class="color-theme-switcher">
  <ClientOnly>
    <SfIcon
      :icon="iconName"
      class="color-theme-switcher__icon"
    />
  
    <span class="color-theme-switcher__text">
      Theme
    </span>
  
    <SfToggleSwitch
      v-model="isDark"
      class="color-theme-switcher__toggler"
    />
  
    <template #placeholder>
      <div class="color-theme-switcher__placeholder" />
    </template>
  </ClientOnly>
</div>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants