title: angular2, directive input OnChanges delay(debounce)?
body: <p>In Angular1, I was able to add add debounce time for <code>ng-model</code>.</p>
  
  <p>In Angular2, we can detect changes on all <code>input</code>. Is it possible to have some debounce time on each input change.</p>
  
  <p>From the following plunker example, <a href="http://plnkr.co/edit/JKYSek?p=preview" rel="nofollow noreferrer">http://plnkr.co/edit/JKYSek?p=preview</a>, I type "hello world", but it reacts to every single key stroke. </p>
  
  <p>Is it possible to have some delay on each change without any programming?</p>
  
  <pre><code>import { Directive, OnChanges } from "@angular/core";
  
  @Directive({
    selector: '[my-directive]',
    inputs: [`myInput`]
  }) 
  export class MyDirective implements OnChanges {
  
    ngOnChanges(changes: {[key: string]: SimpleChange}) {
      console.log('changes :'+ changes.myInput.currentValue);
    }
  }
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/7lDui.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/7lDui.png" alt="enter image description here"></a></p>