Skip to content

Commit a3cc6c1

Browse files
description
1 parent de67045 commit a3cc6c1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# svelte-theme-select
22

3-
Customizable Svelte components for theme selection (light mode / dark mode) inspired by TailwindCSS.
3+
Customizable Svelte components for theme selection (light mode / dark mode) inspired by TailwindCSS. Flicker-free, works with or without SSR and doesn't require unnecessary use of `transformPageChunk` so is cache-friendly.
44

55
<img width="955" alt="svelte-theme-select-dark-mode" src="https://user-images.githubusercontent.com/304910/208352220-3b45ab48-d371-4580-abcf-e55ef872577c.png">
66

@@ -26,7 +26,7 @@ Install using your package manager of choice:
2626

2727
### Add to root +layout.svelte
2828

29-
Include the `<Theme>` component which writes the JS into the page header to apply the theme _before_ hydration (this avoids a flash of the wrong styles). The `<ThemeToggle>` component provides the desktop icon and menu, the `<ThemeSelect>` component provides the mobile friendly equivalent. This is a cut-down layout, checkout the [ready made templates available from TailwindUI](https://tailwindui.com/).
29+
Include the `<Theme>` component which writes the JS into the page header to apply the theme _before_ hydration (this avoids a flash of the wrong styles). The `<ThemeToggle>` component provides the desktop icon and popup menu, the `<ThemeSelect>` component provides the mobile friendly equivalent. This is a cut-down layout, checkout the [ready made templates available from TailwindUI](https://tailwindui.com/).
3030

3131
```svelte
3232
<script lang="ts">

0 commit comments

Comments
 (0)