title: Extend interface defined in .d.ts file
body: <p>In my TypeScript project, I use <a href="https://github.com/borisyankov/DefinitelyTyped" rel="noreferrer">DefinitelyTyped</a> definitions for external js dependencies.</p>
  
  <p>Sometimes it might happen that these definitions are outdated. It might also happen than some libraries can add new methods at runtime, like <a href="https://github.com/ctavan/express-validator" rel="noreferrer">express-validator</a> in which you can define custom validator functions.</p>
  
  <p>Therefore I would like to extend those <code>.d.ts</code> definitions adding new methods and/or properties.</p>
  
  <p>So if I have my DefinitelyTyped defininiton in <code>express-validator.d.ts</code>:</p>
  
  <pre><code>declare module ExpressValidator {
    export interface Validator {
      is(): Validator;
      not(): Validator;
      isEmail(): Validator;
      ...
    }
  }
  </code></pre>
  
  <p>how can I extend <code>Validator</code> interface within, for example, my <code>application.ts</code> ?
  </p>
  
  <pre><code>///&lt;reference path='../typings/tsd.d.ts' /&gt;
  
  import expressValidator = require('express-validator');
  export var app = express();
  
  app.use(expressValidator({
      customValidators: {
          isArray: function(value) {
              return Array.isArray(value);
          }
   }
  }));
  
  // How to extend Validator interface adding isArray() method??
  </code></pre>