2016-04-26 4 views
0

Ich versuche eine Angular2-Anwendung in einer Android-Hybridanwendung zu laden, die WebView verwendet. Die SDK-Version ist 21.Angular2-Anwendung kann in Android WebView API nicht ausgeführt werden. 21

Ich kann die App nicht laden. Es ist nicht in der Lage, boot.js Modul zu laden.

 Errormessage: "undefined is not a function↵ 
Error loading http://example.com/mobile/boot.js"stack: 

"TypeError: undefined is not a function↵  
    at http://example.com/mobile/node_modules/angular2/bundles/angular2.dev.js:764:10↵  
    at http://example.com/mobile/node_modules/angular2/bundles/angular2.dev.js:779:5↵  
    at linkDynamicModule (http://example.com/mobile/node_modules/systemjs/dist/system.src.js:2921:32)↵  
    at getModule (http://example.com/mobile/node_modules/systemjs/dist/system.src.js:2889:9)↵  
    at http://example.com/mobile/node_modules/systemjs/dist/system.src.js:2925:16↵  
    at http://example.com/mobile/node_modules/angular2/bundles/angular2.dev.js:11425:22↵  
    at linkDynamicModule (http://example.com/mobile/node_modules/systemjs/dist/system.src.js:2921:32)↵  
    at getModule (http://example.com/mobile/node_modules/systemjs/dist/system.src.js:2889:9)↵  
    at http://example.com/mobile/node_modules/systemjs/dist/system.src.js:2925:16↵  
    at http://example.com/mobile/node_modules/angular2/bundles/angular2.dev.js:13555:20" 

Es scheint mit dem WebView ein Problem mit der Kompatibilität von SystemJS zu sein, die ich verwende. Ist jemand auf dasselbe Problem gestoßen?

Antwort

1

Das Hinzufügen der SystemJS Polyfüllungen hat den Trick für mich getan.

Verwandte Themen