title: Importing lodash into angular2 + typescript application
body: <p>I am having a hard time trying to get the lodash modules imported. I've setup my project using npm+gulp, and keep hitting the same wall. I've tried the regular lodash, but also lodash-es.</p>
  <p>The lodash npm package: (has an index.js file in the package root folder)</p>
  <pre><code>import * as _ from 'lodash';    
  </code></pre>
  <p>Results in:</p>
  <pre><code>error TS2307: Cannot find module 'lodash'.
  </code></pre>
  <p>The lodash-es npm package: (has a default export in lodash.js i the package root folder)</p>
  <pre><code>import * as _ from 'lodash-es/lodash';
  </code></pre>
  <p>Results in:</p>
  <pre><code>error TS2307: Cannot find module 'lodash-es'.   
  </code></pre>
  <p>Both the gulp task and webstorm report the same issue.</p>
  <p>Funny fact, this returns no error:</p>
  <pre><code>import 'lodash-es/lodash';
  </code></pre>
  <p>... but of course there is no &quot;_&quot; ...</p>
  <p>My tsconfig.json file:</p>
  <pre><code>{
    &quot;compilerOptions&quot;: {
      &quot;target&quot;: &quot;es5&quot;,
      &quot;module&quot;: &quot;system&quot;,
      &quot;moduleResolution&quot;: &quot;node&quot;,
      &quot;sourceMap&quot;: true,
      &quot;emitDecoratorMetadata&quot;: true,
      &quot;experimentalDecorators&quot;: true,
      &quot;removeComments&quot;: false,
      &quot;noImplicitAny&quot;: false
    },
    &quot;exclude&quot;: [
      &quot;node_modules&quot;
    ]
  }
  </code></pre>
  <p>My gulpfile.js:</p>
  <pre><code>var gulp = require('gulp'),
      ts = require('gulp-typescript'),
      uglify = require('gulp-uglify'),
      sourcemaps = require('gulp-sourcemaps'),
      tsPath = 'app/**/*.ts';
  
  gulp.task('ts', function () {
      var tscConfig = require('./tsconfig.json');
      
      gulp.src([tsPath])
          .pipe(sourcemaps.init())
          .pipe(ts(tscConfig.compilerOptions))
          .pipe(sourcemaps.write('./../js'));
  });
  
  gulp.task('watch', function() {
      gulp.watch([tsPath], ['ts']);
  });
  
  gulp.task('default', ['ts', 'watch']);
  </code></pre>
  <p>If I understood correctly, moduleResolution:'node' in my tsconfig should point the import statements to the node_modules folder, where lodash and lodash-es are installed. I've also tried lots of different ways to import: absolute paths, relative paths, but nothing seems to work. Any ideas?</p>
  <p>If necessary I can provide a small zip file to illustrate the problem.</p>