title: Typescript can't find a method defined in a superclass' type definition. What's wrong?
body: <p>I'm using JointJS, which comes with typings defined. There, I have a Typescript class defined like so:</p>
  
  <pre><code>namespace joint {
      namespace shapes {
          namespace devs {
              class Model extends basic.Generic { ... }
          }
      }
  }
  
  namespace basic {
      class Generic extends dia.Element { ... }
  }
  
  namespace dia {
      class Element extends Cell { ... }
      class Cell extends Backbone.Model { ... }
  }
  
  namespace Backbone {
      class Model extends ModelBase {
      ...
      defaults(): ObjectHash;
  }
  </code></pre>
  
  <p>So ultimately, joint.shapes.devs.Model should have that defaults property defined, inherited from <code>Generic &lt;- dia.Element &lt;- dia.Cell &lt;- Backbone.Model</code></p>
  
  <p>However, when I try to extend this object:</p>
  
  <pre><code>const extendedModel = joint.shapes.devs.Model.extend(
      ...
  ), joint.shapes.devs.Model.defaults);
  </code></pre>
  
  <p>...typescript says joint.shapes.devs.Model doesn't have this property defined:</p>
  
  <p><code>error TS2339: Property 'defaults' does not exist on type 'typeof Model'.</code></p>
  
  <p>I tried calling a method instead of just a property:</p>
  
  <pre><code>const extendedModel = joint.shapes.devs.Model.extend(
      ...
  ), joint.shapes.devs.Model.defaults());
  </code></pre>
  
  <p>But I got the same exact message.</p>
  
  <p>I'm on Typescript 2.7.2</p>
  
  <p>My question is: <strong>what is wrong here? How can I fix this?</strong></p>
  
  <p>Thank you!</p>