Comments (5)
Uh, that's a nice idea 👍
The rules' meta
property exposes all the required information about the schema of a rule:
eslint.linter.getRules().get('indent').meta.schema
from eslint-find-rules.
Hi, I'm now analyzing the code for this feature, but I just stuck because I have no idea what is the proper way to display such unused options as an output. For example, you have only specified the first argument (off
, error
, ...) in a rule which can accept bunch of additional and also nested options.
In this case, what would be the best to show on the output? I guess only first level of the options would be sufficient for everyone:
NOTE: The user may need to provide a value to rest of the options to clear the output.
unused options (only first level of full options shown)
indent: [0] -> 'tab' | number, [1] -> {SwitchCase, FooBar, ...} // ['error', 'tab', {SwitchCase, ...}]
padding-line-between-statements: [] -> {blankLine, prev, next} // ['error', {blankLine,prev,next}, ...]
from eslint-find-rules.
Just the names of the options and the rule, and the link to the rule docs, would be sufficient for me.
from eslint-find-rules.
Is there an example of what “names of the options and the rule” would look like?
For example: https://eslint.org/docs/rules/indent
In a rule like “indent”, it may not only accept an object as a options, but also accept primitive values like “tab” or 8
along with other options. What would be the best way to deal with this case? Since a primitive value cannot describe its name unlike a key of an object, I guess showing its value type would be okay.
And there may be nested options where some object can contain another object, what would be the output in this case?
from eslint-find-rules.
I’d be interested in the kinds of options unset, but not their potential values unless it’s an enum or a boolean. In the case of indent, the object option keys is what I’m most interested in.
from eslint-find-rules.
Related Issues (20)
- Scoped plugin error HOT 4
- eslint v6 support HOT 15
- Security warning for "mem" HOT 12
- Doesn't find unused rules in @typescript-eslint/eslint-plugin HOT 4
- Support overrides HOT 14
- eslint v7 support
- Handle typescript-eslint configuration HOT 1
- git clone error on windows HOT 6
- I'm not sure how to deal with renamed rule in ESLint 7.4.0 HOT 7
- Find unused plugin rules
- CHANGELOG missing HOT 3
- Breaks with ESLint 7.8.0 HOT 4
- Update dependencies HOT 5
- Support ESLint 8.x HOT 2
- Add support to the `rule.meta.docs.url` property to get URLs in verbose mode
- Rules in the "rules" json key are not being considered HOT 1
- No Option Provided with `--option` described in docs HOT 1
- Not able to save output as single column HOT 1
- bump `cliui` to resolve `ansi-regex` ReDoS HOT 2
- Support for ESLint 9.x? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from eslint-find-rules.