eslint-config-nhsuk

1.0.0 • Public • Published

NHSUK's ESLint config

GitHub Release npm version Greenkeeper badge Build Status Known Vulnerabilities

This repo provides NHSUK's .eslintrc as a shareable config.

The config is an extension of eslint-config-airbnb-base. Details of the changes can be seen in the exported config defined in index.js. The main changes are the addition of node and mocha environments along with a few small tweaks to the rules. The rule changes better meet the personal preferences of the repo maintainers.

Installation

To install the package run:

  • npm - npm install eslint-config-nhsuk --save-dev
  • yarn - yarn add eslint-config-nhsuk --dev

The config relies upon several other packages. These are the Peer Dependencies. To get a list of the peerDependencies run the following command:

npm info eslint-config-nhsuk peerDependencies

All peerDependencies need to be installed.

Usage

Once the eslint-config-nhsuk package has been installed it is ready to be used. This is achieved by specifying nhsuk in the extends section of your eslint config file. If there is no existing eslint config file it could be as simple as creating a file named .eslintrc with the following content:

{
  "extends": "nhsuk"
}

Package Sidebar

Install

npm i eslint-config-nhsuk

Weekly Downloads

469

Version

1.0.0

License

MIT

Unpacked Size

11.7 kB

Total Files

11

Last publish

Collaborators

  • nhsuk-org
  • mikemonteith
  • st3v3nhunt