title: How to fix "@types/node/index.d.ts is not a module"?
body: <p>I have installed node type definitions using the following command</p>
  
  <pre><code>npm install --save-dev @types/node
  </code></pre>
  
  <p>After that, when I try to import the node type definitions using the following statement</p>
  
  <pre><code>import { Process } from '@types/node';
  </code></pre>
  
  <p>or</p>
  
  <pre><code>import { Process } from 'node';
  </code></pre>
  
  <p>I get the following error</p>
  
  <pre><code>[ts] File '&lt;root_path&gt;/node_modules/@types/node/index.d.ts' is not a module.
  </code></pre>
  
  <p>I am sure there is something very basic that I am missing here but I cannot figure out. </p>
  
  <p>Few more things</p>
  
  <ol>
  <li>I am using Windows 8</li>
  <li>I am using Visual Studio Code</li>
  </ol>
  
  <p>Here is how my <code>tsconfig.json</code> looks</p>
  
  <pre><code>{
    "compilerOptions": {
      "target": "es2015",
      "module": "commonjs",
      "outDir": "lib",
      "typeRoots": [
          "node_modules/@typings"
      ]
    },
    "exclude": [
      "node_modules"
    ]
  }
  </code></pre>
  
  <p>And here is how my <code>webpackconfig.js</code> looks</p>
  
  <pre><code>var path = require('path');
  
  module.exports = {  
    entry: './ts/handler.ts',
    target: 'node',
    module: {
      loaders: [
        { test: /\.ts(x?)$/, loader: 'ts-loader' },      
        { test: /\.json$/, loader: 'json-loader' }
      ]
    },
    resolve: {
      extensions: ['.ts', '.js', '.tsx', '.jsx']
    },
    output: {
      libraryTarget: 'commonjs',
      path: path.join(__dirname, '.webpack'),
      filename: 'handler.js'
    },
  };
  </code></pre>