2.4.5 • Published 1 year ago

eslint-config-qcobjects-typescript v2.4.5

Weekly downloads
-
License
LGPL-3.0
Repository
github
Last release
1 year ago

eslint-config-qcobjects

ESLint Config for QCObjects using TypeScript

Install

  npm i -D eslint-config-qcobjects-typescript

NOTE: Make sure you have installed QCObjects and ESLint before you use this

To install them

  npm i --save-dev qcobjects eslint github:QCObjects/-types-qcobjects github:QCObjects/-types-qcobjects-sdk 

## Settings

Create a .eslintrc.json file with this content

  {
    "extends": [
      "qcobjects-typescript"
    ]
  }

Extended settings to work with modules

Create a .eslintrc.json file with this content

{
    "extends": [
      "qcobjects-typescript"
    ],
    "ecmaFeatures": {
        "modules": true,
        "spread" : true,
        "restParams" : true
    },
    "parserOptions": {
        "sourceType": "module"
    }
  }

Include eslint in your test script in package.json

  npx eslint . --fix
{
  "scripts":{
    "test": "npx eslint . --fix"
  }
}