Closed amr3k closed 1 year ago
Unfortunately there's no support for transformIndexHtml
Vite hook, which is essential for this plugin.
So, AFAICT, the transformIndexHtml
hook is required to inject the style tag and parse the link
tags, right? But if we configure the font link manually, and disable injectAsStyleTag
there should be a way to import the fonts, no?
This issue probably shouldn't be closed yet.
For anyone else ending up at this issue -- I spent way too long trying to hack Sveltekit support into the library, and finally ended up using Fontsource instead, which allows you to install Google fonts as npm packages. Until Sveltekit adds support for transformIndexHtml
, this is probably your best bet.
This plugin does not work with sveltekit!
Here's a stackblitz repro
Please run
npm run build && npm run preview