title: NestJs load environment variables on npm start
body: <p>There`s a more <strong>easy</strong> way to load your env vars using .env files.</p>
  
  <p>Just add <code>--require dotenv/config</code> to your start script, like: <code>node --require dotenv/config server.js</code>.
  <a href="https://github.com/motdotla/dotenv" rel="nofollow noreferrer">https://github.com/motdotla/dotenv</a></p>
  
  <p>But, the problem is that this does not seems to work with nodemon and I can`t figure out how to do it.
  I tried:</p>
  
  <pre><code> "start:dev": "nodemon --require dotenv/config",
  </code></pre>
  
  <p>Can someone help?</p>