How to fix “FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory” error

前端 未结 6 497
再見小時候
再見小時候 2020-12-15 17:52

I\'m trying to deploy a reactjs application to heroku. While compiling assets, the build fails and produces this error:

-----> Ruby app detected
----->         


        
6条回答
  •  有刺的猬
    2020-12-15 18:42

    That problem is related with large files in your project.

    I'm using create-react-app, and I got that error, after doing some search, it seems one solution is this.

    Put in .env file:

    GENERATE_SOURCEMAP=false
    

提交回复
热议问题