Introduction

This package provides .eslintrc.json as an extensible shared config.

What is ESlint ?

ESLint => “Find and fix problems in your JavaScript code”

Installation

You do not need to install it by yourself as it is coming from @dana/tools-cli package.

Configuration

Create a file named .eslintrc.json in the root directory of your project with following json

{
  "extends": [
    "@dana"
  ]
}

Note

if you already have a .eslintrc.json just add @dana to the extends array or add the extends key to your json.

For particular configuration of eslint check here

You can create shortcuts to run linter in your package.json.

{
  "scripts": {
    "lint": "wtv lint",
    "lintdiff": "wtv lintdiff"
  }
}

Usage

Run the following command

npm run lint

Plugins included as dependencies

eslint-config-wtv β”œβ”€β”€ eslint β”œβ”€β”€ eslint-plugin-disable-features (Contains rules to disable certain features) β”œβ”€β”€ eslint-plugin-mocha (ESLint rules for mocha) β”œβ”€β”€ eslint-plugin-wtv (ESLint rules for Dana) └── eslint-plugin-chai-expect (ESLint plugin that checks for common chai.js expect() mistakes)