-
Notifications
You must be signed in to change notification settings - Fork 510
Declaratively specify rule option values #480
Comments
👍 @mikesherov, would we have to do meta-programming to achieve this? One way to go about it is by querying rules directory and strip the names to collect supported rules. But then we would have to look at some other place to find the possible/default values (would be nice if we are able to gather all possible values and enclose them in inline comment The switch name for this may be |
@am11 no need for meta programming, just a set of properties on each rule that defined its accepted / coerced values. |
Actually I was thinking about automating the elicitation process, so no extra work is performed when adding new rules. Or one common place where rules are defined and all adapters will look there for supported rules. |
I just realized that CoffeeScript has a similar switch: |
@mikesherov What if we only allow the creation of jscsrc files based on presets? Something like:
Unless you're thinking of creating a cli that walks you through the creation of a jscsrc, I'm not seeing the value here that warrants the work of changing how we check for valid inputs. |
something like this would be nice: http://browsenpm.org/package.json |
First and second is #895, consider it as sub-task to this issue |
If we are considering auto generating doc blocks as well to be consistent with the specified options, how do we plan on handling good/bad examples? Seems unlikely that we'd be successful at choosing good options for those in code. |
Instead of manually asserting in the
configure
function of a rule, we should be able to specify what values are accepted declaratively. This will also allow us to automate the creation of sample .jscsrc files. In order to do this, we need:Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
The text was updated successfully, but these errors were encountered: