You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
I've been using an .eslintrc file with the prettier plugin for a long time to format code in my Nuxt projects,
I've decided to switch to the new flat config with the @nuxt/eslint module,
(I've seen Antfu's massive work on this project over the last few weeks and I'd like to thank him.)
but I didn't succeed to use the Prettier plugin with this new way of doing things.
I've read a lot about the new ESLint flat config, but I didn't succeed to use plugins with the new withNuxt() method.
I've logged the return value of withNuxt() and I think I can see that there's a plugins object with no name at the end and it's probably making the error for ESLint but really not sure.
Environment
Darwin
v21.7.2
3.11.2
3.11.1
2.9.6
npm@10.5.0
-
ssr
,telemetry
,css
,typescript
,build
,vite
,routeRules
,nitro
,extends
,modules
,app
,site
,ogImage
,sitemap
,robots
,seoExperiments
,schemaOrg
,linkChecker
,ui
,colorMode
,googleFonts
,i18n
,vueEmail
,supabase
,devtools
,runtimeConfig
@nuxt/eslint@0.3.1
,@nuxtjs/i18n@8.3.0
,@nuxt/content@2.12.1
,@nuxt/image@1.5.0
,@nuxt/ui@2.15.1
,@nuxtjs/seo@2.0.0-rc.10
,@nuxtjs/supabase@1.2.0
,@nuxtjs/google-fonts@3.2.0
,@pinia/nuxt@0.5.1
,@vueuse/nuxt@10.9.0
,@vue-email/nuxt@0.8.19
,()
-
Package
@nuxt/eslint
Reproduction
https://stackblitz.com/edit/github-6rwuyx?file=app.vue
Describe the bug
Hello,
I've been using an .eslintrc file with the prettier plugin for a long time to format code in my Nuxt projects,
I've decided to switch to the new flat config with the
@nuxt/eslint
module,(I've seen Antfu's massive work on this project over the last few weeks and I'd like to thank him.)
but I didn't succeed to use the Prettier plugin with this new way of doing things.
I've read a lot about the new ESLint flat config, but I didn't succeed to use plugins with the new withNuxt() method.
I get the error:
With this
eslint.config.mjs
:I've logged the return value of
withNuxt()
and I think I can see that there's a plugins object with no name at the end and it's probably making the error for ESLint but really not sure.Here is the returned content of withNuxt()
Can anyone give me some advice on how to load prettier with this new module?
Thanks in advance!
Additional context
No response
Logs
No response
The text was updated successfully, but these errors were encountered: