title: What is the purpose of the esm directories in the Angular 2 modules?
body: <p>I am working with Angular2 RC4:</p>
  
  <pre><code>    "@angular/common": "2.0.0-rc.4",
      "@angular/compiler": "2.0.0-rc.4",
      "@angular/core": "2.0.0-rc.4",
      "@angular/forms": "0.2.0",
      "@angular/http": "2.0.0-rc.4",
      "@angular/platform-browser": "2.0.0-rc.4",
      "@angular/platform-browser-dynamic": "2.0.0-rc.4",
      "@angular/router": "3.0.0-beta.2",
      "@angular/upgrade": "2.0.0-rc.4",
  </code></pre>
  
  <p>and I am using JetBrains IntelliJ IDEA 2016.2. When I reference Angular2 directives the IDE helpfully offers to import the package in which the directive is defined. Unfortunately the IDE is finding multiple definitions of the directives which means that I have to choose the correct one from a list that is provided. Occasionally I will choose the "wrong" one and I'll end up with a large number of compilation errors. As I've come to learn, the wrong package is always/normally the one in an Angular2 distribution directory containing an <code>esm</code> subfolder.</p>
  
  <p>Upon inspection of any <code>esm</code> folder it's contents closely mimic those of the sibling <code>src</code> folder (for instance):</p>
  
  <pre><code>@angular
    common
    + esm
      + src
        + directives
        + facade
        + form-deprecated
        + location
        + pipes
          common_directives.d.ts
          common_directives.js
          common_directives.js.map
          common_directives.metadata.json
          directives.d.ts
          ...
          pipes.js
          pipes.js.map
    + src
      + directives
      + facade
      + form-deprecated
      + location
      + pipes
        common_directives.d.ts
        common_directives.js
        common_directives.js.map
        common_directives.metadata.json
        directives.d.ts
        ...
        pipes.js
        pipes.js.map
  </code></pre>
  
  <p><strong>Question 1:</strong> What is the purpose of the <code>esm</code> directories and why are these  provided in the distribution?</p>
  
  <p><strong>Question 2:</strong> As an Angular2 application developer do I have need of the files in these directories?</p>
  
  <p><strong>Question 3:</strong> If "No" to question 2 can I safely remove these from my project and/or is there a way to make IntelliJ IDEA 2016.2 ignore these folders?</p>