Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

@losant/eslint-config-losant

1.4.0 • Public • Published

@Losant / Eslint Config Losant

ESLint config for all Losant projects.

Installation

npm install --save-dev @losant/eslint-config-losant
yarn add --dev @losant/eslint-config-losant

Requirements

  • Node.js >=8.0.0

Configuration

Browser

{
  "eslintConfig": {
    "extends": "@losant/eslint-config-losant/env/browser",
  }
}

Node

{
  "eslintConfig": {
    "extends": "@losant/eslint-config-losant/env/node",
  }
}

Usage

You should add an npm script to the package.json of the project that specifies the eslint command. lint is the barebones setup you'll need to then be able to do yarn run lint. It's recommended that you add the other commands as well.

{
  "scripts": {
    "lint": "esw *.js src test",
    "lint:fix": "ews --fix *.js src test",
    "lint:watch": "esw --watch *.js src test",
    "lint:staged": "lint-staged"
  },
  "lint-staged": {
    "*.js": "esw"
  }
}

Documentation

The resulting combination of extended rules, overrides, and plugins are documented together with their specified options:

Keywords

Install

npm i @losant/eslint-config-losant

DownloadsWeekly Downloads

3,462

Version

1.4.0

License

MIT

Unpacked Size

126 kB

Total Files

10

Last publish

Collaborators

  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar