我在過去6個月中一直在使用Angular構建儀表板應用程序,那段時間我使用JiT編譯和gulp瀏覽器同步獲得了非常好的開發工作流程我進行更改時會立即更新。哪個效果很好。Angular AoT和彙總 - 錯誤:沒有加載運行時編譯器
我已經到了很高興部署生產版本的地步,但是,我遇到了AoT和彙總問題。
我都跟着angular.io指導,但得到了下面的
ERROR Error: Uncaught (in promise): Error: Runtime compiler is not loaded
Error: Runtime compiler is not loaded
at _throwError (build.js:5036)
at Compiler.compileModuleAsync (build.js:5065)
at MergeMapSubscriber.project (build.js:34798)
at MergeMapSubscriber._tryNext (build.js:30450)
at MergeMapSubscriber._next (build.js:30440)
at MergeMapSubscriber.Subscriber.next (build.js:425)
at ScalarObservable._subscribe (build.js:846)
at ScalarObservable.Observable._trySubscribe (build.js:708)
at ScalarObservable.Observable.subscribe (build.js:696)
at MergeMapOperator.call (build.js:30415)
at _throwError (build.js:5036)
at Compiler.compileModuleAsync (build.js:5065)
at MergeMapSubscriber.project (build.js:34798)
at MergeMapSubscriber._tryNext (build.js:30450)
at MergeMapSubscriber._next (build.js:30440)
at MergeMapSubscriber.Subscriber.next (build.js:425)
at ScalarObservable._subscribe (build.js:846)
at ScalarObservable.Observable._trySubscribe (build.js:708)
at ScalarObservable.Observable.subscribe (build.js:696)
at MergeMapOperator.call (build.js:30415)
at resolvePromise (zone.js:769)
at resolvePromise (zone.js:740)
at zone.js:817
at ZoneDelegate.invokeTask (zone.js:424)
at Object.onInvokeTask (build.js:6048)
at ZoneDelegate.invokeTask (zone.js:423)
at Zone.runTask (zone.js:191)
at drainMicroTaskQueue (zone.js:584)
at ZoneTask.invoke (zone.js:490)
我還使用了一些可能會造成問題的不同角度的插件(但是我找不到一個任何參考AoT問題),即MyDatePicker
和MyDateRangePicker
。我也有一對夫婦的JS庫,包括D3.js
和momement.js
所以我的問題是,有沒有財產以後,我做錯了,是造成我build.js文件拋出運行時編譯器沒有加載?
如果任何人有任何洞察問題,如果您需要任何特定的代碼片段讓我知道,這將不勝感激,因爲我提到我tsconfig-aot.json
和rollup-config.json
在本質上是相同angular.io
謝謝提前
小地圖複製場景會有所幫助。你有一個github回購,你提取了esssentials的代碼位,可以幫助找出問題並減少修復它的時間? – yurzui
@yurzui我已經添加了一些我認爲可能相關的內容,請告訴我是否需要其他文件。 https://github.com/OliverJACooke/AngularAoTIssues –
你在哪裏使用編譯器?你可以通過使用錯誤callstack來找到它。只要把斷點放在'compileModuleAsync' – yurzui