Skip to content
This repository was archived by the owner on Oct 3, 2023. It is now read-only.

Commit 1056c07

Browse files
committed
Add debounce
1 parent 2c0497e commit 1056c07

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

reactive-demo/src/app/app.component.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ export class AppComponent implements OnInit {
3232
this.transactions$ = Rx.Observable.fromEvent(ws, 'message');
3333
this.transactions$
3434
.map((event: MessageEvent) => event.data)
35+
.debounceTime(500)
3536
.subscribe(inputData => {
3637
const data = JSON.parse(inputData);
3738
console.log(data);

0 commit comments

Comments
 (0)