Angular构建导致错误。-致命错误:接近堆限制的无效标记压缩分配失败-JavaScript堆内存不足

当我试图执行

ng build my.sample.application --prod=false --configuration=dev

我收到如下所示的错误。为了解决这个问题,我执行了

node --max_old_space_size=15000

命令,但问题仍然存在。

错误

严重错误:无效的标记压缩接近堆限制分配失败-JavaScript堆内存不足   1:00007FF6F564094F napi_wrap + 124431   2:00007FF6F55E2696 v8 :: base :: CPU :: has_sse + 34502   3:00007FF6F55E3356 v8 :: base :: CPU :: has_sse + 37766    4:00007FF6F5DE6F4E v8 :: Isolate :: ReportExternalAllocationLimitReached + 94    5:00007FF6F5DCEF91 v8 :: SharedArrayBuffer :: Externalize + 833    6:00007FF6F5C9C85C v8 ::内部::堆:: EphemeronKeyWriteBarrierFromCode + 1436    7:00007FF6F5CA7C00 v8 ::内部::堆::保护未保护的内存块+1312    8:00007FF6F5CA4734 v8 ::内部::堆:: PageFlagsAreConsistent + 3204    9:00007FF6F5C99FC3 v8 ::内部::堆::收集垃圾+1283   10:00007FF6F5C98794 v8 ::内部::堆:: AddRetainedMap + 2356   11:00007FF6F5CC0787 v8 ::内部::工厂:: NewRawTwoByteString + 87   12:00007FF6F5AE797C v8 ::内部::字符串:: SlowFlatten + 492   13:00007FF6F59B110F unibrow :: Utf8 :: EncodeOneByte + 687   14:00007FF6F5DF13A6 v8 :: String :: Utf8Length + 22   15:00007FF6F55FCE0C v8 ::内部:: M已分配::操作符删除+14476   16:00007FF6F5D9B150 v8 ::内部::建筑物:: builtin_handle + 325536   17:00007FF6F5D9A697 v8 ::内部::建筑物:: builtin_handle + 322791   18:00007FF6F5D9A9D8 v8 ::内部::建筑物:: builtin_handle + 323624   19:00007FF6F5D9A7DE v8 ::内部::建筑物:: builtin_handle + 323118   20:00007FF6F6212D6D v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 568205   21:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   22:00007FF6F618BBAC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 14796   23:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   24:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   25:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   26:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   27:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   28:00007FF6F618BBAC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 14796   29:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   30:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   31:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   32:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   33:00007FF6F618BBAC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 14796   34:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   35:00007FF6F618BBAC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 14796   36:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   37:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   38:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   39:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   40:00007FF6F61927FC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 42524   41:00007FF6F618BBAC v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 14796   42:00007FF6F618FDB1 v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 31697   43:00007FF6F618F99C v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 30652   44:00007FF6F5CF4F43 v8 ::内部::执行:: CallWasm + 1395   45:00007FF6F5CF48C6 v8 ::内部::执行::致电+182   46:00007FF6F5DC5B3B v8 :: Function :: Call + 603   47:00007FF6F565CA45节点:: CallbackScope ::〜CallbackScope + 1429   48:00007FF6F5655FE3 v8 ::内部::解释器:: BytecodeNode :: operand_scale + 179   49:00007FF6F55DFBB3 v8 :: base :: CPU :: has_sse + 23523   50:00007FF6F55D4FE1 EVP_CIPHER_CTX_buf_noconst + 200753   51:00007FF6F568CFC7 uv_timer_stop + 775   52:00007FF6F5689AAB uv_async_send + 331   53:00007FF6F568924C uv_loop_init + 1212   54:00007FF6F5689414 uv_run + 244   55:00007FF6F55AB892 EVP_CIPHER_CTX_buf_noconst + 30946   56:00007FF6F5609263节点::开始+275   57:00007FF6F54C666C RC4_options + 339308   58:00007FF6F62C5D58 v8 ::内部:: SetupIsolateDelegate :: SetupHeap + 1301368   59:00007FFB974A13D2 BaseThreadInitThunk + 34   60:00007FFB977654F4 RtlUserThreadStart + 52   npm ERR! Windows_NT 6.3.9600

你们能帮我吗?