File tree Expand file tree Collapse file tree 2 files changed +6
-11
lines changed Expand file tree Collapse file tree 2 files changed +6
-11
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,10 @@ export class AppHostView extends ContentView {
2626 }
2727
2828 this . _content = value ;
29- this . _content . parentNode = this ;
29+
30+ if ( value ) {
31+ this . _content . parentNode = this ;
32+ }
3033
3134 this . ngAppRoot = value ;
3235
Original file line number Diff line number Diff line change @@ -172,7 +172,7 @@ export class NativeScriptPlatformRef extends PlatformRef {
172172 bootstrapLog ( `Angular bootstrap bootstrap done. uptime: ${ uptime ( ) } ` ) ;
173173
174174 if ( ! autoCreateFrame ) {
175- rootContent = this . extractContentFromHost ( tempAppHostView ) ;
175+ rootContent = tempAppHostView . content ;
176176 }
177177
178178 lastBootstrappedModule = new WeakRef ( moduleRef ) ;
@@ -233,7 +233,7 @@ export class NativeScriptPlatformRef extends PlatformRef {
233233 onAfterLivesync . next ( { moduleRef } ) ;
234234
235235 if ( ! autoCreateFrame ) {
236- rootContent = this . extractContentFromHost ( tempAppHostView ) ;
236+ rootContent = tempAppHostView . content ;
237237 }
238238
239239 lastBootstrappedModule = new WeakRef ( moduleRef ) ;
@@ -282,12 +282,4 @@ export class NativeScriptPlatformRef extends PlatformRef {
282282 frame . navigate ( { create : ( ) => { return page ; } } ) ;
283283 return { page, frame } ;
284284 }
285-
286- private extractContentFromHost ( tempAppHostView : AppHostView ) {
287- const result = tempAppHostView . content ;
288- tempAppHostView . content = null ;
289- tempAppHostView . ngAppRoot = result ;
290- result . parentNode = tempAppHostView ;
291- return result ;
292- }
293285}
You can’t perform that action at this time.
0 commit comments