@dwp/eslint-config-base

7.0.0 • Public • Published

@dwp/eslint-config-base

Shareable eslint config enforcing our lint conventions.

Getting started

This configuration assumes that the dependant project is using Prettier to style its code, leaving ESLint to handle the linting of code.

npm install --save-dev @dwp/eslint-config-base eslint

Add an .eslintrc.cjs file that looks something like:

module.exports = {
  extends: ["@dwp/eslint-config-base"],
  env: {
    node: true,
  },
};

Add eslint to your test suite like this, or see our package.json for an example of how we do it:

{
  "scripts": {
    "lint": "eslint ."
  }
}

Rules

This package contains only syntax linting rules, and explicitly excludes any styling rules that may conflict with our recommended styling ruleset, which uses Prettier.

Package Sidebar

Install

npm i @dwp/eslint-config-base

Weekly Downloads

2,435

Version

7.0.0

License

ISC

Unpacked Size

4.11 kB

Total Files

5

Last publish

Collaborators

  • dwp-bot
  • jgdwp
  • lhokktyn
  • adam-moss