JSPM

tslint-config-blvd

1.2.1
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 271
  • Score
    100M100P100Q96396F
  • License Apache-2.0

A TSLint config that conforms to the blvd TypeScript styleguide.

Package Exports

  • tslint-config-blvd

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (tslint-config-blvd) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

tslint-config-blvd

✨ A TSLint config that conforms to the blvd TypeScript styleguide.

Installation

Install tslint and tslint-config-blvd using yarn:

yarn add --dev tslint tslint-config-blvd

or, for npm:

npm install --save-dev tslint tslint-config-blvd

Usage

In your tsconfig.json file, extend tslint-config-blvd.

{
  "extends": "tslint-config-blvd"
}

React rules

We've also included a separate config for React projects. In your tsconfig.json file, extend tslint-config-blvd/react.

{
  "extends": ["tslint-config-blvd/react"]
}

Prettier

Prettier is an automated code formatter for JavaScript, TypeScript, and other languages.

This TSLint config works alongside Prettier, too. To use it, install Prettier as well as tslint-config-prettier to your project.

yarn add --dev prettier tslint-config-prettier

Create a .prettierrc file. Then add the following configs. This should make Prettier automatically format your code based on the blvd guidelines.

{
  "semi": false,
  "tabWidth": 2,
  "printWidth": 140,
  "singleQuote": true,
  "trailingComma": "none"
}

Then include tslint-config-prettier in your project. IMPORTANT: You must add tslint-config-prettier last in the extends array!

{
  "extends": ["tslint-config-blvd/react", "tslint-config-prettier"]
}