svelte-intl-precompile icon indicating copy to clipboard operation
svelte-intl-precompile copied to clipboard

svelte-intl-precompile updates html.lang

Open CarlosAtDexcom opened this issue 1 year ago • 0 comments

I found this piece of code

var $locale = writable("");
$locale.subscribe((newLocale) => {
  setCurrentLocale(newLocale);

  if (typeof window !== "undefined") {
    if (newLocale !== "") {
      document.documentElement.setAttribute("lang", newLocale);
    }
  }
});

its updating the lang attr so I wonder is there any way to prevent this ? since I'd like to update the lang in a diff way.

CarlosAtDexcom avatar Sep 04 '24 21:09 CarlosAtDexcom