How to get FormData in Express js?
<p>I'm trying to upload a file to my express server. The client code looks like this:</p>

<pre><code>axios.post('localhost:3030/upload/audio/', formData)
</code></pre>

<p>And in my express server:</p>

<pre><code>App.use(bodyParser.urlencoded({ extended: true }));
App.use(bodyParser.json());

App.post('/upload/audio/', function uploadAudio(req, res) {
  let quality = ['320', '128'];
  let file = req.body;

  console.log(file)
  res.send('Frick')
}
</code></pre>

<p>However, even though the mp3 file is sent:</p>

<p><a href="https://i.stack.imgur.com/Fkg7K.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Fkg7K.png" alt="http://i.imgur.com/bB7BofH.png"></a></p>

<p>The <code>req.body</code> is empty when logged (note the empty object):</p>

<p><a href="https://i.stack.imgur.com/OV7Hr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/OV7Hr.png" alt="enter image description here"></a></p>

<p>How can I get the formData (and file) in Express.js?</p>