Skip to content

Latest commit

Β 

History

History
639 lines (590 loc) Β· 55.3 KB

ROADMAP.md

File metadata and controls

639 lines (590 loc) Β· 55.3 KB

Roadmap

TSLint rules

βœ… = done
🌟 = in ESLint core
πŸ”Œ = in another plugin
πŸ›‘ = unimplemented
◐ = implementations differ or ESLint version is missing functionality

TypeScript-specific

TSLint rule ESLint rule
adjacent-overload-signatures βœ… typescript/adjacent-overload-signatures
ban-types βœ… typescript/ban-types
member-access βœ… typescript/explicit-member-accessibility
member-ordering βœ… typescript/member-ordering
no-any βœ… typescript/no-explicit-any
no-empty-interface βœ… typescript/no-empty-interface
no-import-side-effect πŸ”Œ import/no-unassigned-import
no-inferrable-types βœ… typescript/no-inferrable-types
no-internal-module βœ… typescript/prefer-namespace-keyword
no-magic-numbers 🌟 no-magic-numbers
no-namespace βœ… typescript/no-namespace
no-non-null-assertion βœ… typescript/no-non-null-assertion
no-parameter-reassignment βœ… no-param-reassign
no-reference βœ… typescript/no-triple-slash-reference
no-unnecessary-type-assertion πŸ›‘ N/A
no-var-requires βœ… typescript/no-var-requires
only-arrow-functions πŸ”Œ prefer-arrow/prefer-arrow-functions
prefer-for-of πŸ›‘ N/A
promise-function-async πŸ›‘ N/A (relevant plugin)
typedef πŸ›‘ N/A
typedef-whitespace βœ… typescript/type-annotation-spacing
unified-signatures πŸ›‘ N/A

Functionality

TSLint rule ESLint rule
await-promise πŸ›‘ N/A
ban-comma-operator 🌟 no-sequences
ban 🌟 no-restricted-properties
curly 🌟 curly
forin 🌟 guard-for-in
import-blacklist 🌟 no-restricted-imports
label-position 🌟 no-unused-labels (similar)
no-arg 🌟 no-caller (also blocks arguments.caller)
no-bitwise 🌟 no-bitwise
no-conditional-assignment 🌟 no-cond-assign[1]
no-console 🌟 no-console (configuration works slightly differently)
no-construct 🌟 no-new-wrappers
no-debugger 🌟 no-debugger
no-duplicate-super 🌟 constructor-super
no-duplicate-switch-case 🌟 no-duplicate-case
no-duplicate-variable 🌟 no-redeclare
no-dynamic-delete πŸ›‘ N/A
no-empty 🌟 no-empty
no-eval 🌟 no-eval
no-floating-promises πŸ›‘ N/A (relevant plugin)
no-for-in-array πŸ›‘ N/A
no-implicit-dependencies πŸ”Œ import/no-extraneous-dependencies
no-inferred-empty-object-type πŸ›‘ N/A
no-invalid-template-strings 🌟 no-template-curly-in-string
no-invalid-this 🌟 no-invalid-this
no-misused-new βœ… typescript/no-misused-new
no-null-keyword πŸ”Œ no-null/no-null (doesn’t handle null type)
no-object-literal-type-assertion βœ… typescript/no-object-literal-type-assertion
no-return-await 🌟 no-return-await
no-shadowed-variable 🌟 no-shadow
no-sparse-arrays 🌟 no-sparse-arrays
no-string-literal 🌟 dot-notation
no-string-throw 🌟 no-throw-literal
no-submodule-imports ◐ import/no-internal-modules (slightly different)
no-switch-case-fall-through 🌟 no-fallthrough
no-this-assignment βœ… typescript/no-this-alias
no-unbound-method πŸ›‘ N/A
no-unnecessary-class βœ… typescript/no-extraneous-class
no-unsafe-any πŸ›‘ N/A
no-unsafe-finally 🌟 no-unsafe-finally
no-unused-expression 🌟 no-unused-expression
no-unused-variable ◐ no-unused-vars [2]
no-use-before-declare βœ… typescript/no-use-before-define
no-var-keyword 🌟 no-var
no-void-expression 🌟 no-void
prefer-conditional-expression πŸ›‘ N/A
prefer-object-spread 🌟 prefer-object-spread
radix 🌟 radix
restrict-plus-operands πŸ›‘ N/A
strict-boolean-expressions πŸ›‘ N/A
strict-type-predicates πŸ›‘ N/A
switch-default 🌟 default-case
triple-equals 🌟 eqeqeq
typeof-compare 🌟 valid-typeof
use-default-type-parameter πŸ›‘ N/A
use-isnan 🌟 use-isnan

[1] The ESLint rule also supports silencing with an extra set of parens (if ((foo = bar)) {})
[2] Missing private class member support. typescript/no-unused-vars adds support for some TS-specific features.

Maintainability

TSLint rule ESLint rule
cyclomatic-complexity 🌟 complexity
deprecation ◐ import/no-deprecated [1]
eofline 🌟 eol-last
indent βœ… typescript/indent or Prettier
linebreak-style 🌟 linebreak-style or Prettier
max-classes-per-file 🌟 max-classes-per-file
max-file-line-count 🌟 max-lines
max-line-length 🌟 max-len or Prettier
no-default-export πŸ”Œ import/no-default-export
no-duplicate-imports πŸ”Œ import/no-duplicates
no-mergeable-namespace πŸ›‘ N/A
no-require-imports πŸ›‘ N/A
object-literal-sort-keys ◐ sort-keys [2]
prefer-const 🌟 prefer-const
prefer-readonly πŸ›‘ N/A
trailing-comma ◐ comma-dangle or Prettier

[1] Only warns when importing deprecated symbols
[2] Missing support for blank-line-delimited sections

Style

TSLint rule ESLint rule
align πŸ›‘ N/A
array-type βœ… typescript/array-type
arrow-parens 🌟 arrow-parens
arrow-return-shorthand 🌟 arrow-body-style
binary-expression-operand-order 🌟 yoda
callable-types πŸ›‘ N/A
class-name βœ… typescript/class-name-casing
comment-format 🌟 capitalized-comments & spaced-comment
completed-docs πŸ”Œ eslint-plugin-jsdoc
encoding πŸ›‘ N/A
file-header πŸ”Œ eslint-plugin-header or -file-header
file-name-casing πŸ”Œ unicorn/filename-case
import-spacing πŸ”Œ Use Prettier
interface-name βœ… typescript/interface-name-prefix
interface-over-type-literal βœ… typescript/prefer-interface
jsdoc-format ◐ valid-jsdoc or eslint-plugin-jsdoc
match-default-export-name πŸ›‘ N/A
newline-before-return 🌟 padding-line-between-statements [1]
newline-per-chained-call 🌟 newline-per-chained-call
new-parens 🌟 new-parens
no-angle-bracket-type-assertion βœ… typescript/no-angle-bracket-type-assertion
no-boolean-literal-compare πŸ›‘ N/A
no-consecutive-blank-lines 🌟 no-multiple-empty-lines
no-irregular-whitespace 🌟 no-irregular-whitespace with skipStrings: false
no-parameter-properties βœ… typescript/no-parameter-properties
no-redundant-jsdoc πŸ›‘ N/A (open issue)
no-reference-import πŸ›‘ N/A
no-trailing-whitespace 🌟 no-trailing-spaces
no-unnecessary-callback-wrapper πŸ›‘ N/A and this might be unsafe (i.e. with forEach)
no-unnecessary-initializer 🌟 no-undef-init
no-unnecessary-qualifier πŸ›‘ N/A
number-literal-format πŸ›‘ N/A
object-literal-key-quotes 🌟 quote-props
object-literal-shorthand 🌟 object-shorthand
one-line πŸ›‘ N/A
one-variable-per-declaration 🌟 one-var
ordered-imports πŸ”Œ import/order
prefer-function-over-method 🌟 class-methods-use-this
prefer-method-signature πŸ›‘ N/A
prefer-switch πŸ›‘ N/A
prefer-template 🌟 prefer-template
prefer-while πŸ›‘ N/A
quotemark 🌟 quotes
return-undefined πŸ›‘ N/A
semicolon 🌟 semi
space-before-function-paren 🌟 space-before-function-paren
space-within-parens 🌟 space-in-parens
switch-final-break πŸ›‘ N/A
type-literal-delimiter βœ… typescript/member-delimiter-style
variable-name 🌟 [2]
whitespace πŸ”Œ Use Prettier

[1] Recommended config: ["error", { blankLine: "always", prev: "*", next: "return" }]
[2] camelcase, no-underscore-dangle, id-blacklist, and/or [id-match]

tslint-microsoft-contrib rules

Rule listing is here. Deprecated rules are excluded (missing-jsdoc, missing-optional-annotation, no-duplicate-case, no-duplicate-parameter-names, no-increment-decrement, no-empty-interfaces, no-missing-visibility-modifiers, no-multiple-var-decl, no-reserved-keywords, no-stateless-class, no-var-self, no-unnecessary-bind, and valid-typeof). See the docs in the link above to find out what to use instead.

Testing

Relevant plugins: chai-expect-keywords, chai-expect, chai-friendly, mocha, and jest

tslint-microsoft-contrib rule ESLint rule
chai-prefer-contains-to-index-of πŸ›‘ N/A
chai-vague-errors πŸ›‘ N/A
mocha-avoid-only πŸ”Œ jest/no-focused-tests
mocha-unneeded-done πŸ›‘ N/A

TypeScript

tslint-microsoft-contrib rule ESLint rule
prefer-array-literal ◐ typescript/no-array-constructor [1]
prefer-type-cast πŸ›‘ N/A

[1] ESLint rule is slightly less strict, allowing new Array<Foo>() and Array(2).

Miscellaneous

tslint-microsoft-contrib rule ESLint rule
export-name πŸ›‘ N/A (relevant plugin)
function-name πŸ›‘ N/A
import-name πŸ›‘ N/A (relevant plugin)
function-name πŸ›‘ N/A
informative-docs πŸ›‘ N/A
insecure-random πŸ”Œ custom implementation
max-func-body-length 🌟 max-statements
no-banned-terms 🌟 [no-callee][no-callee] & no-eval
no-constant-condition 🌟 no-constant-condition
no-control-regex 🌟 no-control-regex
no-delete-expression ◐ no-delete-var
no-empty-line-after-opening-brace 🌟 padded-blocks [1] or Prettier
no-for-in 🌟 no-restricted-syntax [2]
no-function-expression 🌟 func-style [3]
no-invalid-regexp 🌟 no-invalid-regexp
no-multiline-string 🌟 no-multi-str
no-octal-literal 🌟 no-octal-escape, see also no-octal
no-regex-spaces 🌟 no-regex-spaces
no-relative-imports πŸ›‘ N/A, Not recommended by the maintainers
no-single-line-block-comment πŸ›‘ N/A
no-suspicious-comment 🌟 [no-warning-comments][no-warning-comments] [4]
no-typeof-undefined πŸ›‘ N/A (this actually has a valid use: checking if a variable is defined)
no-unexternalized-strings πŸ›‘ N/A
no-unnecessary-field-initialization ◐ no-undef-init [5]
no-unnecessary-local-variable πŸ›‘ N/A
no-unnecessary-override πŸ›‘ N/A
no-unnecessary-semicolons 🌟 no-extra-semi or Prettier
no-useless-files πŸ›‘ N/A
no-with-statement 🌟 no-with
promise-must-complete πŸ›‘ N/A
underscore-consistent-invocation πŸ”Œ lodash/chaining
use-named-parameter πŸ›‘ N/A
use-simple-attributes πŸ›‘ N/A

[1] Enforces blank lines both at the beginning and end of a block
[2] Recommended config: ["error", "ForInStatement"]
[3] Recommended config: ["error", "declaration", { "allowArrowFunctions": true }]
[4] Recommended config: ["error", { "terms": ["BUG", "HACK", "FIXME", "LATER", "LATER2", "TODO"], "location": "anywhere" }]
[5] Does not check class fields.

Security

tslint-microsoft-contrib rule ESLint rule
no-disable-auto-sanitization πŸ›‘ N/A
no-document-domain ◐ Use no-restricted-syntax
no-function-constructor-with-string-args 🌟 no-new-func
no-http-string πŸ›‘ N/A
no-inner-html πŸ›‘ N/A
no-string-based-set-immediate πŸ›‘ N/A
no-string-based-set-interval πŸ›‘ N/A
no-string-based-set-timeout πŸ›‘ N/A
react-iframe-missing-sandbox πŸ›‘ N/A
react-no-dangerous-html πŸ”Œ react/no-danger
non-literal-fs-path πŸ”Œ security/detect-non-literal-fs-filename
non-literal-require πŸ”Œ security/detect-non-literal-require
possible-timing-attack πŸ”Œ security/detect-possible-timing-attacks

Browser

tslint-microsoft-contrib rule ESLint rule
jquery-deferred-must-complete πŸ›‘ N/A
no-backbone-get-set-outside-model πŸ›‘ N/A
no-cookies ◐ Use no-restricted-syntax
no-document-write ◐ Use no-restricted-syntax
no-exec-script ◐ Use no-restricted-syntax
no-jquery-raw-elements πŸ›‘ N/A
no-unsupported-browser-code πŸ”Œ eslint-plugin-compat
react-this-binding-issue πŸ›‘
react-tsx-curly-spacing πŸ”Œ react/jsx-curly-spacing
react-unused-props-and-state ◐ react/no-unused-state

React A11y

tslint-microsoft-contrib rule ESLint rule
react-a11y-accessible-headings ◐ jsx-a11y/heading-has-content [1]
react-a11y-anchors πŸ”Œ jsx-a11y/anchor-is-valid
react-a11y-aria-unsupported-elements πŸ”Œ jsx-a11y/aria-unsupported-elements
react-a11y-event-has-role ◐ jsx-a11y/no-static-element-interactions [2]
react-a11y-image-button-has-alt πŸ”Œ jsx-a11y/alt-text
react-a11y-img-has-alt πŸ”Œ jsx-a11y/alt-text
react-a11y-input-elements πŸ›‘ N/A
react-a11y-lang πŸ”Œ jsx-a11y/html-has-lang & jsx-a11y/lang
react-a11y-meta πŸ›‘ N/A
react-a11y-no-onchange πŸ”Œ jsx-a11y/no-onchange
react-a11y-props πŸ”Œ jsx-a11y/aria-props
react-a11y-proptypes πŸ”Œ jsx-a11y/aria-proptypes
react-a11y-required πŸ›‘ N/A
react-a11y-role-has-required-aria-props πŸ”Œ jsx-a11y/role-has-required-aria-props
react-a11y-role-supports-aria-props πŸ”Œ jsx-a11y/role-supports-aria-props
react-a11y-role πŸ”Œ jsx-a11y/aria-role
react-a11y-tabindex-no-positive πŸ”Œ jsx-a11y/tabindex-no-positive
react-a11y-titles πŸ›‘ N/A
react-anchor-blank-noopener πŸ›‘ N/A

[1] TSLint rule is more strict
[2] ESLint rule only reports for click handlers