angular.js使用ui-router注入报错,这里是版本问题导致的
报错如下:
common.ts:604Uncaught SyntaxError: Unexpected token ) stateEvents.ts:211Uncaught SyntaxError: Unexpected token ) jquery.js:3827 Uncaught Error: [$injector:modulerr] Failed to instantiate module salesApp due to: Error: [$injector:modulerr] Failed to instantiate module ui.router due to: Error: [$injector:nomod] Module 'ui.router' 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. http://errors.angularjs.org/1.3.20/$injector/nomod?p0=ui.router at http://localhost:9006/bower_components/angular/angular.js:63:12 at http://localhost:9006/bower_components/angular/angular.js:1778:17 at ensure (http://localhost:9006/bower_components/angular/angular.js:1702:38) at module (http://localhost:9006/bower_components/angular/angular.js:1776:14) at http://localhost:9006/bower_components/angular/angular.js:4131:22 at forEach (http://localhost:9006/bower_components/angular/angular.js:326:20) at loadModules (http://localhost:9006/bower_components/angular/angular.js:4115:5) at http://localhost:9006/bower_components/angular/angular.js:4132:40 at forEach (http://localhost:9006/bower_components/angular/angular.js:326:20) at loadModules (http://localhost:9006/bower_components/angular/angular.js:4115:5) http://errors.angularjs.org/1.3.20/$injector/modulerr?p0=ui.router&p1=Error…2F%2Flocalhost%3A9006%2Fbower_components%2Fangular%2Fangular.js%3A4115%3A5)
我这个错误是由于版本问题导致的。版本用的比较老,

加上代码:
"angular-ui-router": "1.0.5"
指定了较低的版本之后可以了。
参考博文:
https://code.angularjs.org/1.3.20/docs/error/$injector/modulerr
https://www.jianshu.com/p/85220470cbfe
angular.js使用ui-router注入报错,这里是版本问题导致的的更多相关文章
- IntelliJ IDEA中Mapper接口通过@Autowired注入报错的正确解决方式
转载请注明来源:四个空格 » IntelliJ IDEA中Mapper接口通过@Autowired注入报错的正确解决方式: 环境 ideaIU-2018.3.4.win: 错误提示: Could no ...
- Ionic之$scope 依赖注入报错
在开发Ionic过程中,发现会报在 LoginController 中引用locals报错,具体报错问题: ionic.bundle.js:19526 Error: [$injector:unpr] ...
- angular : $location & $state(UI router)的关系
次序:angular 的 location会先跑 $rootScope.$on("$locationChangeStart", function (scope, newUrl, o ...
- JS 调试中常见的报错的解决办法
报错:Uncaught SyntaxError: Unexpected token o in JSON at position 1 at JSON.parse (<anonymous>) ...
- [转]html页面调用js文件里的函数报错onclick is not defined处理方法
原文地址:http://blog.csdn.net/ywl570717586/article/details/53130863 今天处理html标签里的onclick功能的时候总是报错:Uncaugh ...
- 小程序使用npm模块(引入第三方UI),报错的多种解决办法。
前言引入第三方模块时,我遇到了很多坑. 首先是微信.第三方模块的文档描述不清楚.其次.搜索到的博客,大部分是抄的文档 / 相互转载抄袭.作用有限. 于是,我自己做了各种条件下的测试.解决各种情况的引入 ...
- 【ActiveMQ】消息生产者自动注入报错:Could not autowire. No beans of 'JmsMessagingTemplate' type found
使用ActiveMQ过程中,定义消息生产者: package com.sxd.jms.producer; import org.springframework.beans.factory.annota ...
- MSSQL手工注入 报错注入方法
例子:www.kfgtfcj.gov.cn/lzygg/Zixun_show.aspx?id=1[1]首先爆版本:http://www.kfgtfcj.gov.cn/lzygg/Zixun_show. ...
- Feign 不能注入报错及接口参数问题
无法实例 解决方案: @EnableFeignClients(basePackages = "com.test.test.service") 要指定路径, 如果有设置@Compon ...
随机推荐
- G1 垃圾收集器入门
最近在复习Java GC,因为G1比较新,JDK1.7才正式引入,比较艰难的找到一篇写的很棒的文章,粘过来mark下.总结这篇文章和其他的资料,G1可以基本稳定在0.5s到1s左右的延迟,但是并不能保 ...
- React 记录(7)
React文档:https://www.reactjscn.com/docs/handling-events.html 慢慢学习:对照教程文档,逐句猜解,截图 React官网:https://reac ...
- 第五节:WebApi的三大过滤器
一. 基本说明 1. 简介: WebApi下的过滤器和MVC下的过滤器有一些区别,首先我们要注意的是通常建WebApi项目时,会自动把MVC的程序集也引入进来,所以我们在使用WebApi下的过滤器的 ...
- [物理学与PDEs]第5章第6节 弹性静力学方程组的定解问题
5. 6 弹性静力学方程组的定解问题 5. 6. 1 线性弹性静力学方程组 1. 线性弹性静力学方程组 $$\bee\label{5_6_1_le} -\sum_{j,k,l}a_{ijkl}\cf ...
- v-charts 和 websocket实现数据展示动态推送
v-charts https://v-charts.js.org/#/ ELEMENT力作: 在使用 echarts 生成图表时,经常需要做繁琐的数据类型转化.修改复杂的配置项,v-charts 的出 ...
- volative 与处理器的嗅探技术
在<java并发编程的艺术>这本书中,关于volatile的内存原理本质的描述如下: 有volatile变量修饰共享变量在编译器编译后,后多出一个“lock” 来(lock前缀指令相当于一 ...
- UE4渲染笔记
Lightmass 实时渲染光影效果对性能有很大影响,可利用lightmass预先生成光影贴图,然后在游戏中使用. 将场景光照结果完全烘焙到模型贴图上,从而完完全全的假冒现实光照效果. 文档上是 li ...
- python3: 简单4步骤输出九九乘法表
如何输出一个九九乘法表,使用python语言,嵌套循环,4行代码就可以实现,瞬间感觉python真的很简单~ 代码: for i in range(1,10): for j in range(1,i+ ...
- 全卷积网络 FCN 详解
背景 CNN能够对图片进行分类,可是怎么样才能识别图片中特定部分的物体,在2015年之前还是一个世界难题.神经网络大神Jonathan Long发表了<Fully Convolutional N ...
- python3 字典常见用法总结
python3 字典常见用法总结 Python字典是另一种可变容器模型,且可存储任意类型对象,如字符串.数字.元组等其他容器模型. 一.创建字典 字典由键和对应值成对组成.字典也被称作关联数组或哈希表 ...