diff --git a/package.json b/package.json index eef82c5..6143ba5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "nuxt-font-loader", - "version": "2.3.5", + "version": "2.3.6", "description": "Simple, modern and lightweight font loader for Nuxt.", "author": "Ivo Dolenc", "license": "MIT", diff --git a/src/module.ts b/src/module.ts index 3d9f171..b4bf1e4 100644 --- a/src/module.ts +++ b/src/module.ts @@ -59,7 +59,7 @@ export default defineNuxtModule({ } } - head.style?.push({ children: styles }) + head.style?.push(styles) } if (external) { @@ -111,7 +111,7 @@ export default defineNuxtModule({ ) } - if (styles) head.style?.push({ children: styles }) + if (styles) head.style?.push(styles) } }, }) diff --git a/src/runtime/composables/use-external-font.ts b/src/runtime/composables/use-external-font.ts index bdc2c75..c2982cf 100644 --- a/src/runtime/composables/use-external-font.ts +++ b/src/runtime/composables/use-external-font.ts @@ -54,5 +54,5 @@ export const useExternalFont = (external: ExternalOptions[]) => { useHead({ link: links }) - if (styles) return useHead({ style: [{ children: styles }] }) + if (styles) return useHead({ style: [styles] }) } diff --git a/src/runtime/composables/use-local-font.ts b/src/runtime/composables/use-local-font.ts index 075266a..03a8f50 100644 --- a/src/runtime/composables/use-local-font.ts +++ b/src/runtime/composables/use-local-font.ts @@ -31,5 +31,5 @@ export const useLocalFont = (local: LocalOptions[]) => { if (links.length) useHead({ link: links }) - return useHead({ style: [{ children: styles }] }) + return useHead({ style: [styles] }) }