使用构建电子应用程序将其作为命令行参数传递(例如 myapp.exe --max-old-space-size=4096 或--js-flags='--max-old-space-size=4096' ) 通过创建窗口的 index.js 文件传递它(例如 app.commandLine.appendSwitch('js-flags', '--max-old-space-size=4096'); ) 直接通过 process.env 传递它(process.env[...
How to increase electron max memory limit (--max_old_space_size)#2056(confusion around --max-old-space-size and where to pass it) How Do you pass flages to NodeJS such as '--experimental-worker'?#15748(more asking how to pass flags in) ...
NODE_ENV=production forever start --max-old-space-size=8192 --nouse-idle-notification index.js I get the "forever usage information", as if I had tried to start forever without passing a .js file to run (eg, just typing "forever"). If I put the flags before the "start" command, ...