title: Typescript compiled file cannot find module
body: <p>I have an exported module in one file(parser.js) in Typescript project and I did not generate any error during the compilation phase ,but the Compiled file can't work, This makes me feel confused</p>
  
  <pre class="lang-js prettyprint-override"><code>// parser.d.ts
  declare module 'parser' {
      interface Parser {
          parser(url: string):string
      }
  
      export class UrlParser implements Parser {
          parser(url: string): string  {
              return  url.includes('https') ? url.replace('https', 'http') : '';
          }
      }
  }
  </code></pre>
  
  <pre><code>// parser.js
  export default class UrlParser {
      parser(url)  {
          return  url.includes('https') ? url.replace('https', 'http') : '';
      }
  }
  </code></pre>
  
  <pre class="lang-js prettyprint-override"><code>/// &lt;reference path="../lib/parser.d.ts" /&gt;
  import * as Parser  from 'parser';
  
  let urlParser = new Parser.UrlParser()
  console.log(urlParser.parser('https://www.baidu.com'))
  </code></pre>
  
  <pre><code>// compiled file I got
  "use strict";
  var __importStar = (this &amp;&amp; this.__importStar) || function (mod) {
      if (mod &amp;&amp; mod.__esModule) return mod;
      var result = {};
      if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
      result["default"] = mod;
      return result;
  };
  Object.defineProperty(exports, "__esModule", { value: true });
  /// &lt;reference path="../lib/parser.d.ts" /&gt;
  var Parser = __importStar(require("parser"));
  var urlParser = new Parser.UrlParser();
  console.log(urlParser.parser('https://www.baidu.com'));
  
  </code></pre>
  
  <p>I got an error when I executed the node ./dest/main/js command.</p>
  
  <pre><code>Error: Cannot find module 'parser'
  </code></pre>