8.0.0 • Published 6 months ago

eslint-config-firstvet v8.0.0

Weekly downloads
19
License
ISC
Repository
github
Last release
6 months ago

FirstVet ESLint Rules

  1. From your repository, run npx install-peerdeps -D eslint-config-firstvet. Requires npm 5+.

  2. Create .eslintrc.json in your root and paste one of the following:

JS

{
  "extends": ["firstvet"]
}

JS + Vue

{
  "extends": ["firstvet/vue"]
}

Setup autoformatting on save for VS Code users:

  1. Install VS Code plugin ESLint.

  2. Open your settings.json in VS Code and add/edit the following:

// Turn editor formatting since we will do this via ESLint.
"[javascript]": {
  "editor.formatOnSave": false,
  "editor.formatOnPaste": false,
},
"[json]": {
  "editor.formatOnSave": false,
  "editor.formatOnPaste": false,
},
"[vue]": {
  "editor.formatOnSave": false,
  "editor.formatOnPaste": false,
},
"[typescript]": {
  "editor.formatOnSave": false,
  "editor.formatOnPaste": false,
},

// Tell the ESLint plugin to run on save.
"eslint.validate": ["javascript", "json", "vue", "typescript"],
"editor.codeActionsOnSave": {
  "source.fixAll.eslint": true
},

// Turn off prettier formatting (if previously installed).
"prettier.disableLanguages": ["javascript", "json", "vue", "typescript"],

"path-intellisense.mappings": {
  "@": "${workspaceRoot}/src"
}

Note

There is an issue with VSCode and autoformatting on subdirectories. If the linting rules are used in a subdirectory you will need to open that directory as the "project root" in VSCode for it to work. See thread on StackOverflow.

8.0.0

6 months ago

7.0.0

8 months ago

6.0.0

1 year ago

5.0.0

2 years ago

4.0.0

3 years ago

3.3.0

4 years ago

3.2.0

4 years ago

3.1.0

4 years ago

3.0.0

4 years ago

2.0.0

4 years ago

1.0.13

5 years ago

1.0.11

5 years ago

1.0.12

5 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.10

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago