npm build gives “Ineffective mark-compacts near heap limit Allocation failed”

前端 未结 7 1261
萌比男神i
萌比男神i 2021-02-05 08:44

I have a reactjs/typescript project, running on windows 10. Im trying to build by ts-scripts with

\"rimraf ../wwwroot/* && react-scripts-ts build

7条回答
  •  没有蜡笔的小新
    2021-02-05 08:54

    The solution which I used was to upgrade the node js version from v10 to v12.


    The command export NODE_OPTIONS=--max_old_space_size=4096 works but has limitations, e.g. you should have ample memory on your machine to run the production build.

提交回复
热议问题