-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create rule docs for toggle based on PR feedback
- Loading branch information
Showing
2 changed files
with
31 additions
and
35 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Toggle (`opticks/toggle`) | ||
|
||
Detects stale code from expired Opticks experiments, and other common mistakes related to toggles. | ||
|
||
## Rule Details | ||
|
||
This rule aims to to guide users of Opticks to correct use of the library, as well as indicate which experiments in the code should be considered for clean up. | ||
|
||
### Options | ||
|
||
This rule expects a configuration to be present in order to detect experiments to be cleaned up. | ||
|
||
```json | ||
{ | ||
"settings": { | ||
"opticks": { | ||
"experiments": { | ||
"foo": "a", | ||
"bar": null, | ||
"baz": "b" | ||
} | ||
} | ||
} | ||
} | ||
``` | ||
|
||
By convention, the value of an experiment of `null` means the experiment is still running, and a string value such as `a` or `b` means it's concluded to the side specified and the other sides can be cleaned up. | ||
|
||
## When Not To Use It | ||
|
||
If you don't use Opticks. |