GitHub

Original file line numberDiff line numberDiff line change

@@ -12,13 +12,14 @@ export interface IconProps {

1212

<script setup lang="ts">

1313

import { useForwardProps } from 'reka-ui'

1414

import { reactivePick } from '@vueuse/core'

15+

import NuxtIcon from '@nuxt/icon/runtime/components/index.js'

1516
1617

const props = defineProps<IconProps>()

1718
1819

const iconProps = useForwardProps(reactivePick(props, 'mode', 'size', 'customize'))

1920

</script>

2021
2122

<template>

22-

<Icon v-if="typeof name === 'string'" :name="name" v-bind="iconProps" />

23+

<NuxtIcon v-if="typeof name === 'string'" :name="name" v-bind="iconProps" />

2324

<component :is="name" v-else />

2425

</template>

Read the original on github.com ↗