Speeding up the npm install

前端 未结 8 1885
忘掉有多难
忘掉有多难 2021-02-01 14:54

I am trying to speed up the npm install during the build process phase. My package.json has the list of packages pretty much with locked revisions in it. I\'ve also configured t

相关标签:
8条回答
  • 2021-02-01 15:40

    Nothing helped me more than disabling antivirus (Windows Defender in my case) I got from 2:30 to 1 minute. With npm-cache package I got to ~30 secs. I tried to use yarn, which is very fast, but was randomly failing in my case.

    0 讨论(0)
  • For pure npm solution, you may try

    npm install --prefer-offline --no-audit --progress=false
    

    Prefer offline may not be useful for the first run.

    0 讨论(0)
提交回复
热议问题