Skip to content

Commit e8d5272

Browse files
docs(no-ignored-subscribe): when not to use it
1 parent 47a9090 commit e8d5272

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

docs/rules/no-ignored-subscribe.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,20 @@ import { of } from "rxjs";
2626

2727
of(42, 54).subscribe((value) => console.log(value));
2828
```
29+
30+
## When Not To Use It
31+
32+
If you don't care about errors or output of some observables in your project, you may not need this rule.
33+
Alternatively, you may require all logic to go in the `pipe` section of your observables.
34+
In that case, you should not use this rule and should enable `no-subscribe-handlers` instead, which is the opposite of this rule.
35+
36+
Type checked lint rules are more powerful than traditional lint rules, but also require configuring type checked linting.
37+
38+
## Related To
39+
40+
- [`no-subscribe-handlers`](./no-subscribe-handlers.md)
41+
42+
## Resources
43+
44+
- [Rule source](https://github.com/JasonWeinzierl/eslint-plugin-rxjs-x/blob/main/src/rules/no-ignored-subscribe.ts)
45+
- [Test source](https://github.com/JasonWeinzierl/eslint-plugin-rxjs-x/blob/main/tests/rules/no-ignored-subscribe.test.ts)

0 commit comments

Comments
 (0)