The Jared Wilcurt's Premium Vue.js ESLint rules
This assumes you have ESLint 9+ already set up, if not, refer to this guide.
npm install --save-dev eslint-plugin-vue eslint-config-tjw-vue
- In your
eslint.config.js
:import tjwVue from 'eslint-config-tjw-vue'; import pluginVue from 'eslint-plugin-vue'; const vue2Recommended = pluginVue.configs['flat/vue2-recommended']; const vue3Recommended = pluginVue.configs['flat/recommended']; export default [ // Generic rulesets first, such as: // js.configs.recommended, // tjwBase, // Then pick either Vue 2 or Vue 3 from above and spread it ...vue3Recommended, tjwVue, // Then project specific settings { } ];
See also: