jd-solanki / anu

Anu - DX focused utility based vue component library built on top of UnoCSS & VueUse ⚡️🔥
https://anu-vue.netlify.app/
MIT License
1.04k stars 56 forks source link

nuxt - anu-vue/volar #210

Closed andersonfelix closed 1 year ago

andersonfelix commented 1 year ago

This line: https://github.com/jd-solanki/anu/blob/main/packages/anu-nuxt/src/module.ts#L108

It causes this error:

 ERROR  Cannot read properties of undefined (reading 'push')                                                           8:07:28 PM

  at prepare:types (node_modules/.pnpm/@anu-vue+nuxt@0.15.2_@unocss+reset@0.41.2_@vueuse+core@9.13.0_vue-router@4.2.4/node_modules/@anu-vue/nuxt/dist/shared/nuxt.7768d15e.mjs:7231:38)
  at node_modules/.pnpm/hookable@5.5.3/node_modules/hookable/dist/index.mjs:48:66
  at node_modules/.pnpm/hookable@5.5.3/node_modules/hookable/dist/index.mjs:48:56
  at async writeTypes (node_modules/.pnpm/@nuxt+kit@3.7.0/node_modules/@nuxt/kit/dist/index.mjs:2872:3)
  at async Object.run (node_modules/.pnpm/nuxi@3.7.0/node_modules/nuxi/dist/chunks/prepare.mjs:70:5)
  at async runCommand$1 (node_modules/.pnpm/nuxi@3.7.0/node_modules/nuxi/dist/shared/nuxi.51fb54b9.mjs:1644:5)
  at async runCommand$1 (node_modules/.pnpm/nuxi@3.7.0/node_modules/nuxi/dist/shared/nuxi.51fb54b9.mjs:1638:7)
  at async runMain$1 (node_modules/.pnpm/nuxi@3.7.0/node_modules/nuxi/dist/shared/nuxi.51fb54b9.mjs:1756:7) 

Details:

On File:

Print: console.log(tsConfig.compilerOptions?.types) // undefined

jd-solanki commented 1 year ago

I guess this is related to latest nuxt 3.7. Can you please let me know if this works with nuxt 3.6?

andersonfelix commented 1 year ago

@jd-solanki nuxt 3.6.0 works fine.

Will you check this tsConfig.compilerOptions.types exists?

Thanks

fsyntax commented 1 year ago

Error is also showing up for me on nuxt 3.7.1