title: How to get component selector name inside Directive ? Angular 4
body: <p>I was trying to get selector name inside Directive, I am not sure either is it possible or how to do it. </p>
  
  <pre><code>&lt;my-component1 *myDir="Var"&gt; &lt;/my-component1&gt;
  &lt;my-component2 *myDir="Var"&gt; &lt;/my-component2&gt;
  &lt;my-component3 *myDir="Var"&gt; &lt;/my-component3&gt;
  </code></pre>
  
  <p>i am using same directive on multiple components like given above, now i need to get current component <strong>selector</strong> name inside Directive like below. Please someone tell me how to get selector name inside directive </p>
  
  <pre><code>@Directive({
    selector : '[myDir]
  
  '
      })
  
      export class MyDirDirective {
         constructor (){
           this.currentSelector  = getCurrentComponentSelector;
         }
      }
       @Input() set myDir(value:any){
        if(this.currentSelector==='my-component1'){
            i will do some action, display or not decide
        }
      }
  </code></pre>