title: How to use Angular setter when Input changed?
body: <p>I have two components <code>Parent Component</code> and <code>Child component</code>, I have an API that takes place in the <code>Parent component</code> and the response value is passed to the <code>child component</code>. currently I am using <code>ngOnChanges</code> but I want to know how to use <code>Setters</code> instead.</p>
  <p>assume In the <code>ParentComponent</code> I have the below code:</p>
  <pre><code>&lt;ChildComponent [apiResponse]=&quot;res&quot; /&gt;
  </code></pre>
  <p>and in the <code>ChildComponent</code> I have this:</p>
  <pre><code>@Input() apiResponse: any;
  
  ngOnChanges(changes: SimpleChanges) {
      console.log(this.apiResponse)
  }
  </code></pre>
  <p>Every time the <code>apiResponse</code> changed the <code>ngOnChanges</code> function will fire and prints the value in the console.</p>
  <p>if I want to achieve the result but with the use if <code>Setters</code>. as in other scenario I might have multiple inputs and I don't want <code>ngOnChanges</code> to get fired every time an input's value changed.</p>