I use "angular2 webpack" and "angular2/form,Observable" , but met an error ,need help ..
There is a custom form validator --
import {Observable} from 'rxjs/Rx';
import {REACTIVE_FORM_DIRECTIVES,FormControl, FormGroup, Validators} from '@angular/forms';
emailShouldBeUnique(control:FormControl) {
return new Observable((obs:any)=> {
control.valueChanges
.debouceTime(400)
.distinctUntilChanged()
.flatMap(term=>return !this.userQuery.emailExist(term))
.subscribe(res=> {
if (!res) {obs.next(null)}
else {obs.next({'emailExist': true}); }; }
)});}
I could find the file "/projection_direction/node_modules/rxjs/operator/debounceTime.js"
why is there such the error--
Property 'debouceTime' does not exist on type 'Observable'.