cibernox / svelte-intl-precompile

I18n library for Svelte.js that analyzes your keys at build time for max performance and minimal footprint
https://svelte-intl-precompile.com
ISC License
274 stars 13 forks source link

Doesn't work on @sveltejs/kit versions `1.0.0-next.191` and higher #30

Closed cor closed 2 years ago

cor commented 2 years ago

On sveltekit version 1.0.0-next.190 it works fine, but starting from 191 it produces the following error:

Cannot find package '/Users/cor/Developer/project/node_modules/precompile-intl-runtime/' imported from /Users/cor/Developer/project/node_modules/svelte-intl-precompile/index.js

with precompile-intl-runtime version "0.6.2"

cibernox commented 2 years ago

Thanks for reporting, I haven't updated yet. I'll try to reproduce it tonight.

kbsali commented 2 years ago

same here

cibernox commented 2 years ago

I was able to reproduce it. It seems to be cause by some change in viteJS 2.7 handles dependencies for SSR

cor commented 2 years ago

Alright, would it be difficult to fix?

sastan commented 2 years ago

That was exactly my problem. Sorry. Didn't check this repo for related issues. Should be fixed with https://github.com/cibernox/precompile-intl-runtime/pull/25

cibernox commented 2 years ago

This should be fixed now in 0.6.4. Thanks @sastan for the fix downstream! I'm not sure why Vite 2.7 doesn't handle ESM modules in transitive dependencies anymore.