fix(view): fixed hydrator to export the dom element instead of ng element
This commit is contained in:
parent
abfe175c9e
commit
eac5c88893
|
@ -175,7 +175,7 @@ export class AppViewHydrator {
|
|||
if (elementInjector.isExportingComponent()) {
|
||||
view.locals.set(exportImplicitName, elementInjector.getComponent());
|
||||
} else if (elementInjector.isExportingElement()) {
|
||||
view.locals.set(exportImplicitName, elementInjector.getNgElement());
|
||||
view.locals.set(exportImplicitName, elementInjector.getNgElement().domElement);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -367,7 +367,7 @@ export function main() {
|
|||
|
||||
var value = view.rawView.locals.get('alice');
|
||||
expect(value).not.toBe(null);
|
||||
expect(value.domElement.tagName.toLowerCase()).toEqual('div');
|
||||
expect(value.tagName.toLowerCase()).toEqual('div');
|
||||
|
||||
async.done();
|
||||
})
|
||||
|
@ -383,7 +383,7 @@ export function main() {
|
|||
|
||||
var value = view.rawView.locals.get('superAlice');
|
||||
expect(value).not.toBe(null);
|
||||
expect(value.domElement.tagName.toLowerCase()).toEqual('div');
|
||||
expect(value.tagName.toLowerCase()).toEqual('div');
|
||||
|
||||
async.done();
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue