连接两个模块

时间:2015-11-19 06:51:29

标签: angularjs

我有两个模块:app& myApp。我试图通过将myApp定义为依赖模块来连接两个模块,如下所示:

var app = angular.module('app', ['myModule','ui.router']);

每当我如上所述添加'myModule'时,我都会收到错误:

Uncaught Error: [$injector:modulerr] Failed to instantiate module app due to:
Error: [$injector:modulerr] Failed to instantiate module myModule due to:
Error: [$injector:nomod] Module 'myModule' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.

有人可以帮我吗?

0 个答案:

没有答案