This repository has been archived by the owner on Nov 23, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(core): require issue urls for todos and fixmes
BREAKING CHANGE: all todo and fixme comments are now required to have an issue url attached at the end #8
- Loading branch information
Showing
6 changed files
with
76 additions
and
16 deletions.
There are no files selected for viewing
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
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
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,34 @@ | ||
# Rule Setup | ||
|
||
Instructions on how to setup rules that require configuration | ||
|
||
## `todos/only-documented-todos` | ||
|
||
- This rule checks that all your `FIXMEs` and `TODOs` have an issue url attached to them | ||
|
||
**Setup** | ||
|
||
- Add a new `bugs` section to `package.json` (check the `package.json` example snippet below) that will | ||
contain the `url` where all the issues are opened for your project | ||
- You can find which url to put by opening a single issue, for example | ||
`https://rimac-automobili.atlassian.net/browse/TEL-4380` and taking just the part that will never | ||
change `https://rimac-automobili.atlassian.net/browse/TEL-` and put that in the `url`. Note that only | ||
the issue number at the end changes from issue to issue. | ||
- All the future todo URLs will have to start with that url | ||
- For example for the telemetry project the url is as listed below in the `package.json` example snippet and | ||
the todos should be created as such | ||
|
||
```typescript | ||
// TODO: this needs to be better https://rimac-automobili.atlassian.net/browse/TEL-4380 | ||
const test = 1 | ||
``` | ||
|
||
```json | ||
{ | ||
"name": "@rimac-technology/eslint-config", | ||
"version": "23.0.0", | ||
"bugs": { | ||
"url": "https://rimac-automobili.atlassian.net/browse/TEL-" | ||
} | ||
} | ||
``` |
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
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
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