Express.js Cannot find module 'mime-types'
<p>I'm trying to run a simple express server with body-parser:</p>

<pre><code>var express = require('express');
var bodyParser = require('body-parser');

var app = express();
app.use(bodyParser.json());
</code></pre>

<p>I realize this is no longer bundled with express and have double checked both packages are installed with:</p>

<pre><code>npm install -s express body-parser
</code></pre>

<p>The error I get back is:</p>

<pre><code>module.js:472
    throw err;
    ^

Error: Cannot find module 'mime-types'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object.&lt;anonymous&gt; (/home/osboxes/.nvm/versions/node/v7.2.0/lib/node_modules/body-parser/node_modules/type-is/index.js:16:12)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3)
</code></pre>

<p>I've also tried:</p>

<pre><code> npm install -s mime-types
</code></pre>

<p>which had no effect.</p>

<p><em>Note: I verified that line 4 is where the error occurs by logging before and after.</em> </p>