How to disable vue/multi-word-component-names eslint rule for just one .vue file?

In your case, you can replace ‘vue/multi-word-component-names’: ‘off’ with: ‘vue/multi-word-component-names’: [‘error’, { ‘ignores’: [‘default’] }] this will set the rule to ‘allow’ for all files named ‘default’ you can read more about it here: https://eslint.vuejs.org/rules/multi-word-component-names.html

ESLint broken: Rules with suggestions must set the `meta.hasSuggestions` property to `true`

ESLint 8.0.0 comes with a breaking change for rules that provide suggestions. There is nothing you can put into your .eslintrc.js to make it work if you use rules that haven’t been updated to work after this change. What you can do: Use ESLint 7 until the plugin is updated to work with ESLint 8. … Read more

How to fix just one rule using eslint

To fix the issues caused by just one rule, you need to combine –fix –rule with –no-eslintrc. Otherwise your rule will just be merged with your existing configuration and all fixable issues will be corrected. E.g. $ eslint –no-eslintrc –fix –rule ‘indent: [2, 2]’ Depending on your setup you’ll need to re-add mandatory settings from … Read more

Struggling with TypeScript, React, Eslint and simple Arrow Functions components

Ok, so I don’t know if it is the correct answer, but finally changing the settings in Eslint helped me to change the type of function for Components. I added the following rule to my .eslintrc.js file: “react/function-component-definition”: [ 2, { namedComponents: “arrow-function”, unnamedComponents: “arrow-function”, }, ], With this, eslint will ONLY accept arrow functions … Read more

Ignore or prevent ESLint errors from breaking the build in a React project (create-react-project)

If you want to force ESLint to always emit warnings (that will not stop you build) instead of errors, you need to set emitWarning: true: { enforce: ‘pre’, include: paths.appSrc, test: /\.(js|jsx|mjs)$/, use: [{ loader: require.resolve(‘eslint-loader’), options: { formatter: eslintFormatter, eslintPath: require.resolve(‘eslint’), emitWarning: true, 👈 HERE }, }], }, As stated in the docs: Errors … Read more

ESLint: Parsing error: This experimental syntax requires enabling one of the following parser plugin(s): ‘jsx, flow, typescript’ (2:9)

Install @babel/preset-react in dev dependencies. Add this in .eslintrc file … “parser”: “@babel/eslint-parser”, “parserOptions”: { … “babelOptions”: { “presets”: [“@babel/preset-react”] }, } … Source: https://ffan0811.medium.com/error-debugging-this-experimental-syntax-requires-enabling-one-of-the-following-parser-plugin-s-22946599a0a4