其他分享
首页 > 其他分享> > Angular&CI/CD:Error: initial exceeded maximum budget

Angular&CI/CD:Error: initial exceeded maximum budget

作者:互联网

Angular项目在在走CI/CD流程时,出现以下错误:

Warning: initial exceeded maximum budget. Budget 2.00 MB was not met by 3.01 MB with a total of 5.01 MB.
Error: initial exceeded maximum budget. Budget 5.00 MB was not met by 6.83 kB with a total of 5.01 MB.

大致意思是打包文件过大,超出规定的文件大小

解决方法:修改项目中的angular.json配置文件(内存参数)

 "budgets": [{
                  "type": "initial",
                  "maximumWarning": "2mb",
                  "maximumError": "6mb"
                },
              ]

原来我maximumError设置的5mb,现在设置为6mb就可以了,具体问题视情况而定

标签:CI,MB,initial,maximum,budget,exceeded,total
来源: https://blog.csdn.net/weixin_45680024/article/details/121732976