fix(ivy): o2+ should work with multiple template instances (#22075)
Closes #22075
This commit is contained in:
@ -499,8 +499,7 @@ export function createTView(): TView {
|
||||
contentCheckHooks: null,
|
||||
viewHooks: null,
|
||||
viewCheckHooks: null,
|
||||
destroyHooks: null,
|
||||
objectLiterals: null
|
||||
destroyHooks: null
|
||||
};
|
||||
}
|
||||
|
||||
@ -1736,6 +1735,12 @@ function valueInData<T>(data: any[], index: number, value?: T): T {
|
||||
return value !;
|
||||
}
|
||||
|
||||
/** Gets the binding at the current bindingIndex */
|
||||
export function peekBinding(): any {
|
||||
ngDevMode && assertNotEqual(currentView.bindingStartIndex, null, 'bindingStartIndex');
|
||||
return data[bindingIndex];
|
||||
}
|
||||
|
||||
export function getCurrentQueries(QueryType: {new (): LQueries}): LQueries {
|
||||
return currentQueries || (currentQueries = new QueryType());
|
||||
}
|
||||
@ -1748,10 +1753,6 @@ export function getRenderer(): Renderer3 {
|
||||
return renderer;
|
||||
}
|
||||
|
||||
export function getTView(): TView {
|
||||
return currentView.tView;
|
||||
}
|
||||
|
||||
export function getDirectiveInstance<T>(instanceOrArray: T | [T]): T {
|
||||
// Directives with content queries store an array in data[directiveIndex]
|
||||
// with the instance as the first index
|
||||
|
Reference in New Issue
Block a user