Skip to content

Instantly share code, notes, and snippets.

View hadassegal's full-sized avatar

Hadas Kalimba hadassegal

View GitHub Profile
@ellipizle
ellipizle / async validation with debounce
Created May 4, 2017 19:05
async validation with debounce listening to value change
import { Component, OnInit } from '@angular/core';';
import { FormBuilder, FormGroup, Validators, AbstractControl, ValidationErrors } from '@angular/forms';
import { Router } from '@angular/router'
import { CommonValidators } from '../service/CommonValidator';
import { Response } from '@angular/http';
import { Observable } from 'rxjs/Observable';
import { GlobalService } from '../../shared/service/global.service';
import { AuthHttp } from 'angular2-jwt'
declare var $: any;
import 'rxjs/add/operator/delay';