1.0.0 • Published 4 years ago

@baloise/eslint-config-typescript v1.0.0

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
4 years ago

eslint-config-typescript

NPM package Build Status Sematic-Release

ESLint shareable config for the Baloise style.

TypeScript Rules

Installation

yarn add -D eslint @typescript-eslint/eslint-plugin @typescript-eslint/parser typescript

Create a .eslintrc file with the following content.

{
  "extends": [
    "@baloise/eslint-config-typescript"
  ]
}

Use prettier formatter

yarn add -D prettier eslint-config-prettier

Add prettier and prettier/@typescript-eslint to your .eslintrc file.

{
  "extends": [
    "@baloise/eslint-config-typescript",
    "prettier",
    "prettier/@typescript-eslint"
  ]
}

Create a .prettierrc file with the following content.

{
  "singleQuote": true,
  "semi": false,
  "trailingComma": "all"
}

Open your package.json and add the following script command format.

  "scripts": {
    "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
    ...
  },
1.0.0

4 years ago

0.0.1

4 years ago

0.0.0

4 years ago