reactjs - React 构建未能缩小捆绑包。来自 UglifyJs 的错误
问题描述
当我尝试使用以下命令进行构建时,我的反应应用程序随机停止工作:
npm run-script build
错误是:
无法缩小捆绑包。错误:来自 UglifyJs RangeError 的 static/js/main.4f3a37aa.js:C:\Mist_Applications_Ltd\ASIRTAPORTAL\ASIRTAPORTAL\ClientApp\scripts\build.js:120:23 处 C:\Mist_Applications_Ltd\ASIRTAPORTAL\ASIRTAPORTAL\ClientApp\scripts\build.js:120:23 处的最大调用堆栈大小超出: \Mist_Applications_Ltd\ASIRTAPORTAL\ASIRTAPORTAL\ClientApp\node_modules\webpack\lib\Compiler.js:269:13 在 Compiler.emitRecords (C:\Mist_Applications_Ltd\ASIRTAPORTAL\ASIRTAPORTAL\ClientApp\node_modules\webpack\lib\Compiler.js:375: 38) 在 C:\Mist_Applications_Ltd\ASIRTAPORTAL\ASIRTAPORTAL\ClientApp\node_modules\webpack\lib\Compiler.js:262:10 在 C:\Mist_Applications_Ltd\ASIRTAPORTAL\ASIRTAPORTAL\ClientApp\node_modules\webpack\lib\Compiler.js:368 :12 在编译器的下一个 (C:\Mist_Applications_Ltd\ASIRTAPORTAL\ASIRTAPORTAL\ClientApp\node_modules\tapable\lib\Tapable.js:218:11)。(C:
我的 json 包的 webpack 部分如下所示:
我尝试了很多东西,只是不明白为什么事情突然停止工作!
解决方案
推荐阅读
- terraform - terraform 中不同项目中多个服务帐户的模块
- jira - 报告用户移动特定状态的次数
- plugins - 如何为 Magic Line 配置 CKEditor 以在其他元素上激活?
- shell - “文件意外结束” - 我的代码可能有什么问题?
- wordpress - Wordpress Elementor reCAPTCHA 多个站点键
- jquery - 使用 Ajax 提交 Django 表单时文件/图像字段未提交
- airflow - 气流没有加载我的配置文件
- php - Laravel 将 Authorization Bearer 头设置为空
- python - 如何使用 SQLAlchemy 初始化具有多个值的关联对象的字段?
- python - Django - 外键约束的唯一集合