0.6.12 • Published 3 years ago

@robinblomberg/eslint-config-hac-eslint v0.6.12

Weekly downloads
82
License
ISC
Repository
github
Last release
3 years ago

HAC ESLint

Installation

npm i -D @robinblomberg/eslint-config-hac-eslint

Configuration

Create a file called .eslintrc.js at the project root:

module.exports = {
  extends: '@robinblomberg/hac-eslint'
}

NPM scripts

Add the following scripts to your package.json:

{
  "scripts": {
    "lint-scripts": "eslint \"**/*.{js,jsx,ts,tsx}\"",
    "lint-scripts-fix": "eslint \"**/*.{js,jsx,ts,tsx}\" --fix",
  }
}

Adjust the paths according to your project/file structure as necessary (e.g. "eslint \"src/**/*.{ts,tsx}\"").

To run a script, enter the following in your command line:

npm run lint-scripts

Formatting on Save

With this knowledge of ESLint messages in mind, we can modify VS Code to tell ESLint to fix any issues (mainly formatting) every time we save. To open the settings menu, click on the gear icon in the lower left, and then choose Settings.

Within the settings menu, search for eslint. In the results, you will see a checkbox for ESLint: Auto Fix on Save. Make sure this is checked:

VS Code Settings

Now, save your JavaScript file. You should see some changes, including fewer squiggles.

0.6.12

3 years ago

0.6.10

3 years ago

0.6.11

3 years ago

0.6.7

3 years ago

0.6.6

3 years ago

0.6.9

3 years ago

0.6.8

3 years ago

0.6.5

3 years ago

0.6.4

3 years ago

0.6.3

3 years ago

0.6.2

3 years ago

0.6.1

3 years ago

0.6.0

3 years ago

0.6.0-beta.1

3 years ago

0.5.12

3 years ago

0.5.11

3 years ago

0.5.10

3 years ago

0.5.9

3 years ago

0.5.8

3 years ago

0.5.7

3 years ago

0.5.6

3 years ago

0.5.5

3 years ago

0.5.2

4 years ago

0.5.1

4 years ago

0.5.0

4 years ago

0.4.6

4 years ago

0.4.3

4 years ago

0.4.2

4 years ago

0.4.1

4 years ago

0.4.0

4 years ago

0.3.5

4 years ago

0.3.4

4 years ago

0.3.3

4 years ago

0.3.2

4 years ago

0.3.1

4 years ago

0.3.0

4 years ago