Skip to content
This repository has been archived by the owner on Jul 1, 2020. It is now read-only.
/ tslint-no-unused Public archive

A TSLint rule for detecting unused locals and properties (for TS 2.9+)

License

Notifications You must be signed in to change notification settings

strax/tslint-no-unused

Repository files navigation

tslint-no-unused

Build Status

A TSLint rule to make unused locals and properties lint errors.

This rule essentially acts like TypeScript's noUnusedLocals and noUnusedProperties combined, except that by using TSLint the actual compilation is not affected.

no-unused is a replacement for TSLint's deprecated builtin no-unused-variable rule, but also works with tslint-language-service.

This rule uses TypeScript 2.9's new unused diagnostics, so TS 2.9 or newer is required.

Usage

Add tslint-no-unused to your project's dev dependencies and add the following to your tslint.json:

{
  "extends": ["tslint-no-unused"],
  "rules": {
    "no-unused": true
  }
}

About

A TSLint rule for detecting unused locals and properties (for TS 2.9+)

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published