New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

eslint-plugin-ts

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-ts

ESLint TypeScript plugin

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
278
decreased by-9.45%
Maintainers
1
Weekly downloads
 
Created
Source

ESLint-plugin-ts

TypeScript specific linting rules for ESLint

Installation

Install ESLint either locally or globally.

$ npm i eslint --save-dev

If you installed ESLint globally, you have to install the plugin globally too. Otherwise, install it locally.

$ npm i eslint-plugin-ts --save-dev

Install typescript-eslint-parser either locally or globally.

$ npm i typescript-eslint-parser --save-dev

Configuration

Use the recommended preset to get reasonable defaults:

  "extends": [
    "eslint:recommended",
    "plugin:ts/recommended"
  ]

If you do not use a preset you will need to specify individual rules and add extra configuration.

Add "ts" to the plugins section.

{
  "plugins": ["ts"]
}

You will need to configure the TypeScript parser.

{
  "parser": "eslint-typescript-parser"
}

Enable the rules that you would like to use.

  "rules": {
    "ts/no-any": "error"
  }

List of supported rules

  • ts/no-any: Forbid the usage of the "any" type annotation

License

ESLint-plugin-ts is licensed under the MIT License.

Keywords

FAQs

Package last updated on 02 Oct 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc