title: Nodejs Express - how to set max-old-space-size in package.json?
body: <p>I was getting Javascript heap out of memory error. </p>
  
  <p>So I made this change to my package.json file.</p>
  
  <pre><code>  "scripts": {
      "start": "node --max-old-space-size=4096 app.js &amp;&amp; node ./bin/www"
    },
  </code></pre>
  
  <p>which used to be </p>
  
  <pre><code>  "scripts": {
      "start": "node ./bin/www",
    },
  </code></pre>
  
  <p>Now if I run npm start, the server is not up and running. If I try to access any page, I get unable to connect to server error message.</p>
  
  <p>What am I doing wrong?</p>
  
  <p>Thanks.</p>