2019-02-27 14:30:38 -05:00
|
|
|
load("//tools:defaults.bzl", "jasmine_node_test", "ts_library")
|
|
|
|
|
|
|
|
ts_library(
|
|
|
|
name = "test_lib",
|
|
|
|
testonly = True,
|
|
|
|
srcs = glob(["**/*.ts"]),
|
|
|
|
data = [
|
2019-04-29 15:17:03 -04:00
|
|
|
"//packages/core/schematics:migrations.json",
|
2019-02-27 14:30:38 -05:00
|
|
|
],
|
|
|
|
deps = [
|
2020-09-26 14:35:25 -04:00
|
|
|
"//packages/core/schematics/migrations/abstract-control-parent",
|
2020-12-11 20:16:54 -05:00
|
|
|
"//packages/core/schematics/migrations/can-activate-with-redirect-to",
|
feat(core): add dynamic queries schematic (#32231)
Adds a schematic that will remove the explicit `static: false` flag from dynamic queries. E.g.
```ts
import { Directive, ViewChild, ContentChild, ElementRef } from '@angular/core';
@Directive()
export class MyDirective {
@ViewChild('child', { static: false }) child: any;
@ViewChild('secondChild', { read: ElementRef, static: false }) secondChild: ElementRef;
@ContentChild('thirdChild', { static: false }) thirdChild: any;
}
```
```ts
import { Directive, ViewChild, ContentChild, ElementRef } from '@angular/core';
@Directive()
export class MyDirective {
@ViewChild('child') child: any;
@ViewChild('secondChild', { read: ElementRef }) secondChild: ElementRef;
@ContentChild('thirdChild') thirdChild: any;
}
```
PR Close #32231
2019-08-21 01:40:30 -04:00
|
|
|
"//packages/core/schematics/migrations/dynamic-queries",
|
2019-10-13 00:25:58 -04:00
|
|
|
"//packages/core/schematics/migrations/initial-navigation",
|
2019-06-10 13:08:54 -04:00
|
|
|
"//packages/core/schematics/migrations/missing-injectable",
|
2019-10-17 02:40:36 -04:00
|
|
|
"//packages/core/schematics/migrations/module-with-providers",
|
2019-04-17 00:06:06 -04:00
|
|
|
"//packages/core/schematics/migrations/move-document",
|
2020-09-17 09:12:08 -04:00
|
|
|
"//packages/core/schematics/migrations/native-view-encapsulation",
|
2020-09-12 08:33:06 -04:00
|
|
|
"//packages/core/schematics/migrations/navigation-extras-omissions",
|
2020-06-05 22:40:13 -04:00
|
|
|
"//packages/core/schematics/migrations/relative-link-resolution",
|
2019-06-09 09:38:18 -04:00
|
|
|
"//packages/core/schematics/migrations/renderer-to-renderer2",
|
2020-10-12 14:13:57 -04:00
|
|
|
"//packages/core/schematics/migrations/router-preserve-query-params",
|
2019-02-27 14:30:38 -05:00
|
|
|
"//packages/core/schematics/migrations/static-queries",
|
2019-03-30 07:48:21 -04:00
|
|
|
"//packages/core/schematics/migrations/template-var-assignment",
|
2019-08-15 05:40:53 -04:00
|
|
|
"//packages/core/schematics/migrations/undecorated-classes-with-decorated-fields",
|
2019-07-24 06:07:07 -04:00
|
|
|
"//packages/core/schematics/migrations/undecorated-classes-with-di",
|
2020-10-12 12:07:34 -04:00
|
|
|
"//packages/core/schematics/migrations/wait-for-async",
|
2019-02-27 14:30:38 -05:00
|
|
|
"//packages/core/schematics/utils",
|
2019-05-09 17:51:51 -04:00
|
|
|
"@npm//@angular-devkit/core",
|
2019-02-27 14:30:38 -05:00
|
|
|
"@npm//@angular-devkit/schematics",
|
|
|
|
"@npm//@types/shelljs",
|
2019-03-13 11:29:25 -04:00
|
|
|
"@npm//tslint",
|
2019-02-27 14:30:38 -05:00
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
jasmine_node_test(
|
2019-08-26 10:12:44 -04:00
|
|
|
name = "test",
|
2019-04-10 00:13:14 -04:00
|
|
|
deps = [
|
|
|
|
":test_lib",
|
|
|
|
"@npm//shelljs",
|
|
|
|
],
|
2019-02-27 14:30:38 -05:00
|
|
|
)
|