You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`tslint-modular` is a set of [configuration presets](https://palantir.github.io/tslint/usage/configuration/#configuration-presets) for [TSLint](https://palantir.github.io/tslint/) that's broken-up into different modules that can be mixed-and-matched to match the needs of your project.
13
+
TSLint Modular is a set of [configuration presets](https://palantir.github.io/tslint/usage/configuration/#configuration-presets) for [TSLint](https://palantir.github.io/tslint/) that's broken-up into different modules that can be mixed-and-matched to match the needs of your project.
14
14
15
15
Each module defines rules that are meant to be reasonable defaults and best practices, but you can easily extend or override any of the rules to suit your needs.
16
16
@@ -24,10 +24,10 @@ Related Projects
24
24
25
25
Installation
26
26
-----------------------
27
-
Run the following [npm](https://docs.npmjs.com/about-npm/) command to install [TSLint](https://palantir.github.io/tslint/) and `tslint-modular` as dev-dependencies of your project:
27
+
Run the following [npm](https://docs.npmjs.com/about-npm/) command to install [TSLint](https://palantir.github.io/tslint/) and `@jsdevtools/tslint-modular` as dev-dependencies of your project:
Contains rules that prevent accidental bugs, insecure code, and bad coding practices. You can use this module directly, or use any/all of its sub-modules.
Prevents syntax that is likely to lead to accidental bugs or runtime errors. Examples include not [duplicate variables](https://palantir.github.io/tslint/rules/no-duplicate-variable/), and [using `===` instead of `==`](https://palantir.github.io/tslint/rules/triple-equals) for comparisons. Most of the rules in this file will raise an error if violated, but some less-severe ones will only raise warnings.
Helps you write code that is more maintainable over time and by multiple people. For example, [limiting cyclomatic complexity](https://palantir.github.io/tslint/rules/cyclomatic-complexity) and [keeping files short](https://palantir.github.io/tslint/rules/max-file-line-count).
Helps enforce security best-practices such as [avoiding the `eval()` statement](https://palantir.github.io/tslint/rules/no-eval) and [not calling the `Function` constructor](https://palantir.github.io/tslint/rules/function-constructor).
Bans bad practices for web-based code, such as [the `alert()` statement](https://eslint.org/docs/rules/no-alert#disallow-use-of-alert-no-alert) and the jQuery global.
Discourages deprecated and outdated Node.js code, such as [`fs.exists()`](https://nodejs.org/api/fs.html#fs_fs_exists_path_callback). It encourages using more modern syntax, such as [the `fs.promises` API](https://nodejs.org/api/fs.html#fs_fs_promises_api).
Code-commenting rules, such as [documenting all public members](https://palantir.github.io/tslint/rules/completed-docs/), using [JSDoc format](https://palantir.github.io/tslint/rules/jsdoc-format/), and not [duplicating type information](https://palantir.github.io/tslint/rules/no-redundant-jsdoc/) in comments.
Enforces an **opinionated** set of conventions, such as using [double-quotes](https://palantir.github.io/tslint/rules/quotemark/) and [semi-colons](https://palantir.github.io/tslint/rules/semicolon).
Encourages good JavaScript naming conventions, such as [camel-case variables](https://palantir.github.io/tslint/rules/variable-name) and [capitialized classes](https://palantir.github.io/tslint/rules/class-name).
Disallows outdated, nonstandard, and confusing syntax. Examples include [labels](https://palantir.github.io/tslint/rules/label-position), [the comma operator](https://palantir.github.io/tslint/rules/ban-comma-operator), and [parameter properties](https://palantir.github.io/tslint/rules/no-parameter-properties).
Enforces **opinionated** whitespace rules, such as [two-space indentation](https://palantir.github.io/tslint/rules/indent), [opening braces on the same line](https://palantir.github.io/tslint/rules/one-line), and [type definition spacing](https://palantir.github.io/tslint/rules/typedef-whitespace).
Warns about `describe.only()` and `it.only()` calls that may have accidentally been left in your test code.
99
99
100
100
> **Note:** We recommend that you create a separate `tslint.yaml` file in your test folder. That way, it can use different modules and rules than the rest of your codebase.
0 commit comments