Express - can't serve static files (404 error)
<p>I came across many questions like these but it doesn't look like I'm doing anything wrong. The problem is that I can't get my static files to load.</p>

<p><strong>Folder structure:</strong></p>

<pre><code>/client
    index.html
    /assets
        /css
            main.css
/server
    app.js
</code></pre>

<p><strong>app.js:</strong></p>

<pre><code>var assetsPath = path.join(__dirname, '../client/assets');
app.use(express.static('assetsPath'));

app.get('/', function (req, res) {
    res.sendFile(path.join(__dirname, '../client/' + 'index.html'));
});

app.listen(PORT, function () {
    console.log('\nListening on port 8080!');
});
</code></pre>

<p><strong>index.html</strong></p>

<pre><code>&lt;link rel="stylesheet" href="/css/main.css"&gt;
</code></pre>

<p>Yet when loading the page in the browser, I get 404 on <code>http://localhost:8080/css/main.css</code> </p>

<p>Is there anything missing?</p>

<p>Thank you!</p>

<p><em>PS: using express ^4.13.4 &amp; node v5.10.1</em></p>