JavaScript heap out of memory when building Vue.js app
问题 I'm trying to build a vue.js app for production. This error message always appears midway through. FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory I already tried to increase the memory by adding --max_old_space_size=4096 and even tried to change it to 8192, but to no avail. I am using a Mac with 8 GB of RAM so I'm not sure why this is happening. This is the code I run for npm run build : vue-cli-service build --max_old_space_size=4096