ivanhofer / typesafe-i18n-demo-sveltekit

A small project demonstrating a `typesafe-i18n` integration with SvelteKit
https://typesafe-i18n-demo-sveltekit.vercel.app
130 stars 19 forks source link

Tailwind issue #29

Closed marksteven closed 1 year ago

marksteven commented 1 year ago

Tried taking your boilerplate - installed working fine Then added popular css module Tailwindcss npx svelte-add@latest tailwindcss

which broke it with token error

{$page.data.title || 'typesafe-i18n'}
               ^

20 | Not quite sure why here Now attempting to build SvelteKit/Tailwind boilerplate and then use your steps to add i18n Will post here if I am successful Hope this helps

marksteven commented 1 year ago

Further testing. Something I have not come across. It seems installing Tailwind runs a few scripts that rebuilt a number of pages that Tailwind deemed written wrong and broke. +layout.svelte being the main one. Breaking the i18n capability of switching languages. Fixing +layout.svelte got project to run properly so my suggestion to anyone else trying is keep a separate copy of +layout.svelte whilst you load Tailwind and repair if needed.

ivanhofer commented 1 year ago

Thanks for sharing this. I'll close this issue, since it it not related to typesafe-i18n.