Angular js App缩小 [英] Angular js App minification

查看:53
本文介绍了Angular js App缩小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

非常受欢迎的问题:


未知提供者:nProvider<-n<-$ http<-$ templateFactory<- $ view
<-$ state

Unknown provider: nProvider <- n <- $http <- $templateFactory <- $view <- $state

我为此使用MVC捆绑。

I use MVC Bundling for this.

如何阅读此消息?

这是否意味着 $ state 需要 $ view 是否需要 $ templateFactory 等?

Does it mean that $state requires $view that requires $templateFactory etc.?

推荐答案

在某些外部指令中存在问题。因此,我遍历了所有这些内容以及服务注入的固定语法:

It was a problem in some external directives. So I go through all of them and fixed syntax of service injections:

from

app.service('myService', function($scope, $animate) {});

app.service('myService', ['$scope', '$animate', function($scope, $animate) {}]);

要了解问题所在,
我已将所有脚本添加到index.html。然后开始逐步使用MVC捆绑包缩小脚本。之后,我发现了错误的缩小脚本。

To understand where is the problem I have added all scripts to index.html. And then start to minificate scripts with MVC bundle part by part. After this I have found the incorrect for minification script.

这篇关于Angular js App缩小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆