Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

List all rules that haven't been specified in your tslint.json #2444

Closed
ghost opened this issue Mar 30, 2017 · 5 comments
Closed

List all rules that haven't been specified in your tslint.json #2444

ghost opened this issue Mar 30, 2017 · 5 comments

Comments

@ghost
Copy link

ghost commented Mar 30, 2017

Wow, tslint has improved so much - awesome! However, there are so many new rules now it's hard to keep track of them.

Is there a way to list all rules that haven't been explicitly specified in your tslint.json?

That way, when new rules come out, I can just run a command, look at the list of new rules that aren't specified in my tslint.json, read up on the documentation and specify them. This is better than my suboptimal eyeballing at the moment.

@adidahiya
Copy link
Contributor

Fair point. We're working on a tslint:all configuration that lists all the rules (#2417). Do you think that sufficiently addresses this problem?

It would also be pretty easy to write a Node script to compare your list of configured rules to the list of files that match node_modules/tslint/lib/rules/*Rule.js. This code does something close to this.

@ghost
Copy link
Author

ghost commented Mar 31, 2017

How about if you use custom rules, like tslint-react, etc.?

Is there some code path which reads the extends & rulesDirectory settings and makes a list of every single rule available? Then I can use this to diff against tslint.json.

@ghost
Copy link
Author

ghost commented Apr 1, 2017

Hacked up something just now: https://github.com/khoomeister/check-tslint-all

@JoshuaKGoldberg
Copy link
Contributor

Thanks for that check-tslint-all! This seems out of scope for TSLint itself, so closing this issue for now. If there's a spike in interest we can always revisit.

@bhavnaberi
Copy link

This feature will be very helpful for developers as they can quickly check as to which rules have been newly added.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants