Skip to content

Commit

Permalink
docs(takeUntil): update docs to match operator's behavior
Browse files Browse the repository at this point in the history
2160
  • Loading branch information
martinsik authored and staltz committed Nov 2, 2017
1 parent 1f55dad commit 27a7df9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion doc/decision-tree-widget/tree.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ children:
- label: based on a given amount
children:
- label: takeLast
- label: until another Observable emits a value or completes
- label: until another Observable emits a value
children:
- label: takeUntil
- label: I want to ignore values
Expand Down
5 changes: 3 additions & 2 deletions src/operator/takeUntil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,15 @@ import { takeUntil as higherOrder } from '../operators/takeUntil';
* Observable emits a value.
*
* <span class="informal">Lets values pass until a second Observable,
* `notifier`, emits something. Then, it completes.</span>
* `notifier`, emits a value. Then, it completes.</span>
*
* <img src="./img/takeUntil.png" width="100%">
*
* `takeUntil` subscribes and begins mirroring the source Observable. It also
* monitors a second Observable, `notifier` that you provide. If the `notifier`
* emits a value, the output Observable stops mirroring the source Observable
* and completes.
* and completes. If the `notifier` doesn't emit any value and completes
* then `takeUntil` will pass all values.
*
* @example <caption>Tick every second until the first click happens</caption>
* var interval = Rx.Observable.interval(1000);
Expand Down
7 changes: 4 additions & 3 deletions src/operators/takeUntil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,15 @@ import { MonoTypeOperatorFunction } from '../interfaces';
* Observable emits a value.
*
* <span class="informal">Lets values pass until a second Observable,
* `notifier`, emits something. Then, it completes.</span>
* `notifier`, emits a value. Then, it completes.</span>
*
* <img src="./img/takeUntil.png" width="100%">
*
* `takeUntil` subscribes and begins mirroring the source Observable. It also
* monitors a second Observable, `notifier` that you provide. If the `notifier`
* emits a value or a complete notification, the output Observable stops
* mirroring the source Observable and completes.
* emits a value, the output Observable stops mirroring the source Observable
* and completes. If the `notifier` doesn't emit any value and completes
* then `takeUntil` will pass all values.
*
* @example <caption>Tick every second until the first click happens</caption>
* var interval = Rx.Observable.interval(1000);
Expand Down

0 comments on commit 27a7df9

Please sign in to comment.