Angular Meteor应用程序在localhost中工作,但在部署到服务器时失败

Angular Meteor app works in localhost but fails when deployed to server

本文关键字:部署 服务器 失败 工作 应用程序 Meteor localhost Angular      更新时间:2023-09-26

使用angular-with-blaze包的Angular Meteor应用程序在localhost上运行良好,但当部署到使用mupmupx的服务器时,站点会部分加载,并在浏览器JS控制台中抛出以下错误:

Error: [$injector:modulerr] Failed to instantiate module myApp due to:
Error: [$injector:unpr] Unknown provider: e

考虑到这是由于JS文件的缩小,我尝试了以下mupx设置,但没有帮助。

"buildOptions": {
  // build with the debug mode on
  "debug": true
}

有关于解决此问题的建议吗?

如果您分别使用gump或grunt ng注释,请尝试使用gump任务"gump ng注释"。它将根据角度依赖性注释为模块中的依赖性添加所需的注释。