Skip to content

Commit fa0b6ca

Browse files
inklesscyril-sf
authored andcommitted
Fix emberApp's query selector (emberjs#730)
The applicationView's selector was hard coded to `body > .ember-view`, this does not work for applications that are not using body as their rootElement. We need to respect rootElement.
1 parent 78ada41 commit fa0b6ca

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

ember_debug/view-debug.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ export default EmberObject.extend(PortMixin, {
298298
if (!emberApp) {
299299
return false;
300300
}
301-
let applicationView = document.querySelector('body > .ember-view');
301+
let applicationView = document.querySelector(`${emberApp.rootElement} > .ember-view`);
302302
let applicationViewId = applicationView ? applicationView.id : undefined;
303303
let rootView = this.get('viewRegistry')[applicationViewId];
304304
// In case of App.reset view is destroyed

0 commit comments

Comments
 (0)