Import vs Require in Typescript
<p>While I was going through Angular2 documentation, I came across below code in <a href="https://angular.io/docs/ts/latest/guide/webpack.html" rel="noreferrer">here</a>.</p>

<p>src/polyfills.ts</p>

<pre><code>import 'core-js/es6';
import 'core-js/es7/reflect';
require('zone.js/dist/zone');

if (process.env.ENV === 'production') {
 // Production
} else {
 // Development
Error['stackTraceLimit'] = Infinity;
require('zone.js/dist/long-stack-trace-zone');
}
</code></pre>

<p>In the above code we can see that there are both <code>import</code> and <code>require</code> statements. </p>

<p>"core-js" and "zone.js" are both node modules.</p>

<p>My question is; why is <code>import</code> used for core-js and <code>require</code> for "zone.js", is there any specific reason for this?</p>