ng build throws Cannot read property 'startTag' of null exception

坚强是说给别人听的谎言 提交于 2020-02-25 07:12:17

问题


I want to publish my Angular 8 app to IIS. Then I've started to follow the deployment instructions. When I build my project on prod mode with base-href, operation throws an error. If I build in development mode(just ng build), there is no error but I have to build in production mode. --base-href causes the error. What can I do now?

Here is error:

Cannot read property 'startTag' of null TypeError: Cannot read property 'startTag' of null at Object.augmentIndexHtml (D:\ReklamUssuProjects\DevBranch\RULink\RULink.UI\Angular\node_modules@angular-devkit\build-angular\src\angular-cli-files\utilities\index-file\augment-index-html.js:126:55) at compiler.hooks.emit.tapPromise (D:\ReklamUssuProjects\DevBranch\RULink\RULink.UI\Angular\node_modules@angular-devkit\build-angular\src\angular-cli-files\plugins\index-html-webpack-plugin.js:70:60)


回答1:


When I asked to github angular cli issues, problem was solved. Thank you again.

Github Link



来源:https://stackoverflow.com/questions/57754746/ng-build-throws-cannot-read-property-starttag-of-null-exception

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!