title: Typescript: esnext compiler option destroys es6 import from external lib
body: <p>When setting ether the <code>module</code> or <code>target</code> property of the compiler options to esnext (id like to use <code>import("example")</code> statements), es6 import statements stop working for <code>npm install</code>ed librarys (local modules sill work: e.g. <code>"./test.ts"</code>).</p>
  
  <p>So this <code>import * as asd from "testmodule";</code> throws <code>cannot find module 'testmodule'</code>. However omitting both properies makes it work. Why is this and what es standard should I use to keep <code>import("example")</code> and <code>import * as asd from "testmodule";</code> statements?</p>
  
  <hr>
  
  <p>Here is my full tsconfig.json:</p>
  
  <pre><code>{
    "compilerOptions": {
      "outDir": "./dist/",
      "module": "esnext",
      "target": "esnext",
      "allowJs": true,
      "sourceMap": true
    }
  }
  
  </code></pre>