Tagged: node

0

Debug mocha using visual studio code

Add the fol­low­ing con­fig­u­ra­tion in your launch.json { “name”: “Run mocha”, “type”: “node”, “request”: “launch”, “pro­gram”: “${workspaceRoot}/node_modules/mocha/bin/mocha”, “sto­pO­nEn­try”: false, “args”: [ “test/**/*.js”, “–inspect”, “–debug-brk”, “–no-timeouts” ], “cwd”: “${work­space­Root}”, “run­time­Ex­e­cutable”: null, “env”: { “NODE_ENV”: “testing”…

0

Call and retry last Allocation failed

Solu­tion: node –max–old-space-size=4096 <file­name> You need to tell node to over­write default heap size in v8. To see all the avail­able v8 flags run the fol­low­ing com­mand: node –v8-options –Fur­ther details on chromium bug