Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ESLint 9: defineTemplateBodyVisitor is not a function #108

Closed
simon-kolkmann opened this issue Nov 18, 2024 · 1 comment
Closed

ESLint 9: defineTemplateBodyVisitor is not a function #108

simon-kolkmann opened this issue Nov 18, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@simon-kolkmann
Copy link

simon-kolkmann commented Nov 18, 2024

I'm just checking out the newly added ESLint 9 support, but the plugin throws an error:

> eslint .

Oops! Something went wrong! :(

ESLint: 9.15.0

TypeError: Error while loading rule 'vuetify/no-deprecated-classes': context.sourceCode.parserServices.defineTemplateBodyVisitor is not a function
Occurred while linting /path/to/project/.prettierrc.js
    at Object.create (/path/to/project/node_modules/eslint-plugin-vuetify/lib/rules/no-deprecated-classes.js:33:46)
    at createRuleListeners (/path/to/project/node_modules/eslint/lib/linter/linter.js:944:21)
    at /path/to/project/node_modules/eslint/lib/linter/linter.js:1082:84
    at Array.forEach (<anonymous>)
    at runRules (/path/to/project/node_modules/eslint/lib/linter/linter.js:1013:34)
    at #flatVerifyWithoutProcessors (/path/to/project/node_modules/eslint/lib/linter/linter.js:1911:31)
    at Linter._verifyWithFlatConfigArrayAndWithoutProcessors (/path/to/project/node_modules/eslint/lib/linter/linter.js:1993:49)
    at Linter._verifyWithFlatConfigArray (/path/to/project/node_modules/eslint/lib/linter/linter.js:2082:21)
    at Linter.verify (/path/to/project/node_modules/eslint/lib/linter/linter.js:1543:61)
    at Linter.verifyAndFix (/path/to/project/node_modules/eslint/lib/linter/linter.js:2320:29)
  • ESLint: 9.15.0
  • eslint-plugin-vue: 9.31.0
  • eslint-plugin-vuetify: 2.5.0

My ESLint configuration is copied from the docs:

import vue from 'eslint-plugin-vue'
import vuetify from 'eslint-plugin-vuetify'

export default [...vue.configs['flat/base'], ...vuetify.configs['flat/base']]

The .prettierrc.js file in question looks like this:

export { default } from '@my-org/prettier-config'
@KaelWD KaelWD added the bug Something isn't working label Nov 18, 2024
@KaelWD KaelWD closed this as completed in c703efe Nov 18, 2024
@simon-kolkmann
Copy link
Author

@KaelWD Thanks for the quick fix! 💯

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants