@nuxtjs/apollo not working with nuxt4
I had a nuxt 3 project that use
I tried removing and installing
@nuxtjs/apollo@nuxtjs/apollo package to handle GraphQL queries and mutation after I migrated to nuxt 4 using ncu -uncu -u I am getting this error:warn: incorrect peer dependency "graphql@16.11.0"
warn: incorrect peer dependency "graphql@16.11.0"
warn: incorrect peer dependency "graphql@16.11.0"
warn: incorrect peer dependency "graphql@16.11.0"
$ nuxt prepare
ERROR Cannot read properties of undefined (reading 'build') 1:52:32 PM
at module.exports (node_modules/@nuxtjs/apollo/lib/module.js:7:39)
at callModule (node_modules/nuxt/node_modules/@nuxt/kit/dist/index.mjs:784:208)
at installModules (node_modules/nuxt/node_modules/@nuxt/kit/dist/index.mjs:660:11)
at async initNuxt (node_modules/nuxt/dist/index.mjs:5383:3)
at async loadNuxt (node_modules/nuxt/dist/index.mjs:5585:5)
at async loadNuxt (node_modules/nuxt/node_modules/@nuxt/kit/dist/index.mjs:982:16)
at async Object.run (node_modules/@nuxt/cli/dist/chunks/prepare.mjs:32:18)
at async runCommand (node_modules/citty/dist/index.mjs:316:16)
at async runCommand (node_modules/citty/dist/index.mjs:307:11)
at async runMain (node_modules/citty/dist/index.mjs:445:7)warn: incorrect peer dependency "graphql@16.11.0"
warn: incorrect peer dependency "graphql@16.11.0"
warn: incorrect peer dependency "graphql@16.11.0"
warn: incorrect peer dependency "graphql@16.11.0"
$ nuxt prepare
ERROR Cannot read properties of undefined (reading 'build') 1:52:32 PM
at module.exports (node_modules/@nuxtjs/apollo/lib/module.js:7:39)
at callModule (node_modules/nuxt/node_modules/@nuxt/kit/dist/index.mjs:784:208)
at installModules (node_modules/nuxt/node_modules/@nuxt/kit/dist/index.mjs:660:11)
at async initNuxt (node_modules/nuxt/dist/index.mjs:5383:3)
at async loadNuxt (node_modules/nuxt/dist/index.mjs:5585:5)
at async loadNuxt (node_modules/nuxt/node_modules/@nuxt/kit/dist/index.mjs:982:16)
at async Object.run (node_modules/@nuxt/cli/dist/chunks/prepare.mjs:32:18)
at async runCommand (node_modules/citty/dist/index.mjs:316:16)
at async runCommand (node_modules/citty/dist/index.mjs:307:11)
at async runMain (node_modules/citty/dist/index.mjs:445:7)I tried removing and installing
@nuxtjs/apollo@nuxtjs/apollo package but I am still getting this error in the installation process