Rxjs: use debounceTime on angular 6 width RxJs 6

Created on 22 May 2018  路  2Comments  路  Source: ReactiveX/rxjs

Hello i just upgrade my web app from angular 5 to 6 and i have a problem width debounceTime

import { debounceTime } from 'rxjs/operators';
this.form.valueChanges.debounceTime(500).subscribe(val => {
// ...
});

error TS2339: Property 'debounceTime' does not exist on type 'Observable'.

Someone have a solution ?
thanks

Most helpful comment

If you're using rxjs 6 without rxjs-compat, try

this.form.valueChanges.pipe(debounceTime(500)).subscribe(val => {
...
})

All 2 comments

If you're using rxjs 6 without rxjs-compat, try

this.form.valueChanges.pipe(debounceTime(500)).subscribe(val => {
...
})

Yeah It's Work !!

Thanks !!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

LittleFox94 picture LittleFox94  路  3Comments

benlesh picture benlesh  路  3Comments

cartant picture cartant  路  3Comments

Agraphie picture Agraphie  路  3Comments

shenlin192 picture shenlin192  路  3Comments