Skip to content

Commit 968700c

Browse files
pkozlowski-opensourcedevversion
authored andcommitted
refactor(core): rename queryCreate to viewQueryCreate
In the end we need to distinguish between view and content query creation and need separate names for those instructions.
1 parent f108800 commit 968700c

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

packages/core/src/core_reactivity_export_internal.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,5 @@ export {
3939
export {input} from './render3/reactivity/input';
4040
export {InputSignal, ɵɵGetInputSignalWriteType} from './render3/reactivity/input_signal';
4141
export {ModelSignal} from './render3/reactivity/model_signal';
42-
export {viewChild, viewChildren, ɵɵqueryCreate} from './render3/reactivity/queries';
42+
export {viewChild, viewChildren, ɵɵviewQueryCreate} from './render3/reactivity/queries';
4343
// clang-format on

packages/core/src/render3/reactivity/queries.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ export class ChildrenQuerySignalImpl<T> extends QuerySignal<T> {
8080
}
8181

8282
// THINK: code duplication for predicate, flags etc.? Or would it be extracted by the compiler?
83-
export function ɵɵqueryCreate<T>(
83+
export function ɵɵviewQueryCreate<T>(
8484
target: Signal<T|undefined>, predicate: ProviderToken<unknown>|string[], flags: QueryFlags,
8585
read?: any) {
8686
const lView = getLView();

packages/core/test/acceptance/signal-components/queries.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* found in the LICENSE file at https://angular.io/license
77
*/
88

9-
import {Component, computed, ElementRef, ViewChild, viewChild, viewChildren, ɵɵdefineComponent, ɵɵelement, ɵɵqueryCreate, ɵɵStandaloneFeature} from '@angular/core';
9+
import {Component, computed, ElementRef, ViewChild, viewChild, viewChildren, ɵɵdefineComponent, ɵɵelement, ɵɵStandaloneFeature, ɵɵviewQueryCreate} from '@angular/core';
1010
import {TestBed} from '@angular/core/testing';
1111

1212

@@ -62,7 +62,7 @@ describe('queries', () => {
6262
function App_Query(rf, ctx) {
6363
// TODO: there should be no update mode for queries any more
6464
if (rf & 1) {
65-
ɵɵqueryCreate(ctx.divEl, _c0, 1);
65+
ɵɵviewQueryCreate(ctx.divEl, _c0, 1);
6666
}
6767
},
6868
standalone: true,
@@ -100,7 +100,7 @@ describe('queries', () => {
100100
function App_Query(rf, ctx) {
101101
// TODO: there should be no update mode for queries any more
102102
if (rf & 1) {
103-
ɵɵqueryCreate(ctx.divEls, _c0, 1);
103+
ɵɵviewQueryCreate(ctx.divEls, _c0, 1);
104104
}
105105
},
106106
standalone: true,

0 commit comments

Comments
 (0)