title: partially inject components in typescript (angularjs)
body: <p>currently I use <code>$inject</code> to inject components in my controller:</p>
  
  <pre><code>export class MyClass{
  
      public static $inject = [
          "$depedencyA",
          "$depedencyB",
          "$depedencyC"   
      ];
  
      constructor(
              private $depedencyA: IDependencyA,
              private $depedencyB: IDependencyB,
              private $depedencyC: IDependencyC         
          )
          {
  
          }
  
  }
  </code></pre>
  
  <p>This works fine when creating an instance of <code>MyClass</code> like <code>let myClassInstance=new MyClass();</code></p>
  
  <p>But what if I want to pass a depedency that cannot be directly injected by the class itself?</p>
  
  <p><code>let myClassInstance=new MyClass(anotherDependency);</code></p>
  
  <p>Well of course I have to extend <code>MyClass</code> to accept this parameter in the constructor </p>
  
  <pre><code>constructor(
              private $depedencyA: IDependencyA,
              private $depedencyB: IDependencyB,
              private $depedencyC: IDependencyC,
              private $anotherDependency: any
          )
          {
  
          }
  </code></pre>
  
  <p>..but then the injection cannot work anymore because the parameters array does not match the actual constructur signature anymore.
  How do I work around this?</p>