执行ng build --prod --aot命令报错
D:\git\**\src\main\iui>ng build --prod --aot
Hash: 257ab60feca43633b6f7
Time: 25358ms
chunk {0} polyfills.221420fde500aaed5079.bundle.js (polyfills) 184 kB {5} [initial] [rendered]
chunk {1} scripts.92391f7b3a5602225e85.bundle.js (scripts) 185 kB {5} [initial] [rendered]
chunk {2} styles.429bdc2066b527f64acc.bundle.css (styles) 281 bytes {5} [initial] [rendered]
chunk {3} main.bfbde393948c0a677c68.bundle.js (main) 1.1 kB {4} [initial] [rendered]
chunk {4} vendor.d9800c734c7708c02954.bundle.js (vendor) 851 kB [initial] [rendered]
chunk {5} inline.d70fd8c806a11fd8fd6e.bundle.js (inline) 0 bytes [entry] [rendered]
ERROR in ./src/main.ts
Module not found: Error: Can't resolve './$$_gendir/app/app.module.ngfactory' in 'D:\git\**\src\main\iui\src'
@ ./src/main.ts 3:0-74
@ multi ./src/main.ts
ERROR in ./src/$$_gendir async
Module not found: Error: Can't resolve 'D:\git\**\src\main\iui\src\$$_gendir\app\upgrade\upgrade.module.ngfactory.ts' in 'D:\git\**\src\main\iui\src\$$_gendir'
@ ./src/$$_gendir async
@ ./~/@angular/core/@angular/core.es5.js
@ ./src/main.ts
@ multi ./src/main.ts
如上,执行ng build --prod --aot会报错,去掉–aot后可正常编译通过。网上查找解决方法可升级@angular/cli版本,或者执行 npm install enhanced-resolve@3.3.0 命令,本人使用第二种方法成功解决了问题,第二种不成功可升级cli后再试。
执行ng build --prod --aot命令报错的更多相关文章
- mac上执行sed的编辑 -i命令报错sed: 1: "test.txt": undefined label ‘est.txt’或sed: 1: "2a\test\": extra characters after \ at the end of a command
问题一 sed编辑命令:[sed -i 's/a/b/g' test.txt] 报错:sed: 1: "test.txt": undefined label 'est.txt' ...
- MySQL执行外部sql脚本文件命令报错:unknown command '\'
由于编码不一致导致的 虽然大部分导出是没有问题的 但是数据表中存储包含一些脚本(富文本内容)会出现该问题,强制指定编码即可解决. mysql导入时指定编码: mysql -u root -p --de ...
- angular ng build --prod 打包报错解决方案
使用以下代码 就不报错了 ng build --prod --no-extract-license 打包命令 使用以下代码 就不报错了 ng build --prod --no-extrac ...
- angular2 ng build --prod 报错:Module not found: Error: Can't resolve './$$_gendir/app/app.module.ngfactory'
调试页面 ng serve 正常 ng build 也正常 ng build --prod 异常:Module not found: Error: Can't resolve './$$_gendir ...
- Angular6之ng build | ng build --aot | ng build --prod 差异
由于写了大半年的项目终于要告一段落并且即将进行第二阶段优化开发,emmm 基础版本已经二十多个模块了,必不可少的优化是很重要的,尽管项目上使用多层嵌套懒加载,但是在首屏加载的时候,任然很慢啊,因为一直 ...
- ng build --aot 与 ng build --prod
angluar的编译有以下几种方式: ng build 常规的压缩操作 代码体积最大 ng build --aot angular预编译 代码体积较小 ng build --pr ...
- 安装atlas后执行hive命令报错
在集群中安装atlas,在安装atlas的节点上执行hive -e "show databases;" 正常,但是在集群中其他节点上执行hive -e "show dat ...
- 执行Spark运行在yarn上的命令报错 spark-shell --master yarn-client
1.执行Spark运行在yarn上的命令报错 spark-shell --master yarn-client,错误如下所示: // :: ERROR SparkContext: Error init ...
- Python3安装Celery模块后执行Celery命令报错
1 Python3安装Celery模块后执行Celery命令报错 pip3 install celery # 安装正常,但是执行celery 命令的时候提示没有_ssl模块什么的 手动在Python解 ...
随机推荐
- ACM学习历程—HDU1028 Ignatius and the Princess III(递推 || 母函数)
Description "Well, it seems the first problem is too easy. I will let you know how foolish you ...
- Oracle日期范围
一.SQL语句: select to_date(to_char(to_date('2017-10-01', 'yyyy-mm-dd') + rownum - 1, 'yyyy-mm-dd'), 'yy ...
- Tomcat的安装及使用
下面是我搭建Tomcat的过程,记录一下 下载地址:http://tomcat.apache.org/ 我下载的是8.5.30版本 安装 下载完成后解压到D盘 (配置变量的的教程网上大把随便搜) 1 ...
- Python文件运行时报TabError: inconsistent use of tabs and spaces in indentation
1. 问题描述 Python文件运行时报TabError: inconsistent use of tabs and spaces in indentation 2. 问题原因 tab 和 space ...
- Inno Setup整理
1.如何使inno setup添加快捷方式默认选中 在[Tasks]段,有 Flags:unchecked改成 Flags: checkablealone; 即可 完整代码示例: [Tasks] Na ...
- java之装箱拆箱
参考http://how2j.cn/k/number-string/number-string-wrap/22.html 封装类 所有的基本类型,都有对应的类类型 比如int对应的类是Integer ...
- java之二叉树--未完待续
参考http://how2j.cn/k/collection/collection-tree/476.html#nowhere 二叉树概念 二叉树由各种节点组成二叉树特点:每个节点都可以有左子节点,右 ...
- HTML页面弹出窗口调整代码总结
弹出跟你当前的窗口有没有菜单工具栏没有关系,你只要在页面中写一个脚本它就弹出了.比如<a href=# onclick="window.open('xxx.aspx','窗口名称',' ...
- HRBUST - 1214 NOIP2000提高组 方格取数(多线程dp)
方格取数 设有N*N的方格图(N<=10),我们将其中的某些方格中填入正整数,而其他的方格中则放人数字0.如下图所示(见样例 ,黄色和蓝色分别为两次走的路线,其中绿色的格子为黄色和蓝色共同走过的 ...
- Apache Shiro知识点总览
名词解释 权限认证 授权 ini文件配置 jsp标签授权 Shiro会话机制 自定义Realm 加密.解密 特性 与spring整合 名词解释 Subject:认证主体 Reaml:认证来源[jdbc ...