TSLint Config DVHB
Basic TSLint config for DVHB projects
Installation
npm install @dvhb/tslint-config --save-dev
Usage
In tslint.json
:
{
"extends": "@dvhb/tslint-config"
}
Extends
- tslint-config-airbnb — rules based on Airbnb JavaScript Style Guide
- tslint-config-prettier — disables all rules that may cause conflicts with prettier
- tslint-plugin-prettier — runs Prettier as a TSLint rule
Rules
-
no-console
— forbidsconsole.log()
-
prettier
— checks code style with Prettier -
variable-name
— restrict variables names to camelCase-
allow-pascal-case
— for classes, constructors and react components name -
allow-leading-underscore
— fornoUnusedParameters
TS rule when required parameter of function is not first
-