Skip to content

Instantly share code, notes, and snippets.

@MuXiu1997
Last active July 23, 2021 09:16
Show Gist options
  • Select an option

  • Save MuXiu1997/d4e2e08d7ded833614c316b3bc7fe1d0 to your computer and use it in GitHub Desktop.

Select an option

Save MuXiu1997/d4e2e08d7ded833614c316b3bc7fe1d0 to your computer and use it in GitHub Desktop.
[vue3 + eslint] #vue #eslint
module.exports = {
root: true,
env: {
node: true,
},
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:vue/vue3-recommended',
'plugin:prettier/recommended'
],
parser: 'vue-eslint-parser',
parserOptions: {
parser: '@typescript-eslint/parser',
tsconfigRootDir: __dirname,
project: './tsconfig.json',
extraFileExtensions: ['.vue'],
ecmaVersion: 2020,
},
rules: {
// ...
},
}
{
"semi": false,
"singleQuote": true
}
# npm i -D \
yarn add -D \
prettier eslint \
@typescript-eslint/eslint-plugin @typescript-eslint/parser `# eslint + typescript` \
eslint-plugin-prettier eslint-config-prettier `# eslint + prettier` \
eslint-plugin-vue `# eslint + vue`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment