nuxt / icon

The <Icon> component, supporting Iconify, Emojis and custom components.
https://stackblitz.com/edit/nuxt-icon-playground?file=app.vue
MIT License
957 stars 58 forks source link

Cannot read properties of undefined (reading 'startsWith') #190

Closed syifeng closed 4 months ago

syifeng commented 4 months ago

I got the exception when i use the @nuxt/icon and nuxt-icon 1.0.0-beta.7, I just try both version. And I got the same error.

here is the dependencies "dependencies": { "big.js": "^6.2.1", "nuxt": "^3.12.3", "nuxt-icon": "1.0.0-beta.7", "qrcode-vue3": "^1.6.8", "vue": "latest" }, "devDependencies": { "@formkit/auto-animate": "^0.8.2", "@nuxtjs/tailwindcss": "^6.12.0", "@pinia-plugin-persistedstate/nuxt": "^1.2.1", "@pinia/nuxt": "^0.5.1", "@vueuse/nuxt": "^10.11.0" }

Cannot read properties of undefined (reading 'startsWith')

at ReactiveEffect.fn (./node_modules/.pnpm/@vue+reactivity@3.4.31/node_modules/@vue/reactivity/dist/reactivity.cjs.js:994:13) at ReactiveEffect.run (./node_modules/.pnpm/@vue+reactivity@3.4.31/node_modules/@vue/reactivity/dist/reactivity.cjs.js:172:19) at get value [as value] (./node_modules/.pnpm/@vue+reactivity@3.4.31/node_modules/@vue/reactivity/dist/reactivity.cjs.js:1006:109) at ./node_modules/.pnpm/nuxt-icon@1.0.0-beta.7_magicast@0.3.4_rollup@4.18.0vite@5.3.3@types+node@20.14.10_terser@5.31.1__vue@3.4.31/node_modules/nuxt-icon/dist/runtime/components/index.js:36:44 at ReactiveEffect.fn (./node_modules/.pnpm/@vue+reactivity@3.4.31/node_modules/@vue/reactivity/dist/reactivity.cjs.js:994:13) at ReactiveEffect.run (./node_modules/.pnpm/@vue+reactivity@3.4.31/node_modules/@vue/reactivity/dist/reactivity.cjs.js:172:19) at get value [as value] (./node_modules/.pnpm/@vue+reactivity@3.4.31/node_modules/@vue/reactivity/dist/reactivity.cjs.js:1006:109) at Proxy. (./node_modules/.pnpm/nuxt-icon@1.0.0-beta.7_magicast@0.3.4_rollup@4.18.0vite@5.3.3@types+node@20.14.10_terser@5.31.1__vue@3.4.31/node_modules/nuxt-icon/dist/runtime/components/index.js:43:17) at renderComponentRoot (./node_modules/.pnpm/@vue+runtime-core@3.4.31/node_modules/@vue/runtime-core/dist/runtime-core.cjs.js:886:16)

danjrwalsh commented 4 months ago

@syifeng Would you be able to provide a repro for this?

Also please use @nuxt/icon and not nuxt-icon

antfu commented 4 months ago

We temporarily closed this due to the lack of enough information. We could not identify whether it was a bug or a userland misconfiguration with the given info. Please provide a minimal reproduction to reopen the issue. Thanks.

Why reproduction is required