@angular-devkit/schematics 19.0.0-next.9 → 19.0.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular-devkit/schematics",
3
- "version": "19.0.0-next.9",
3
+ "version": "19.0.0-rc.0",
4
4
  "description": "Angular Schematics - Library",
5
5
  "main": "src/index.js",
6
6
  "typings": "src/index.d.ts",
@@ -18,9 +18,9 @@
18
18
  "tooling"
19
19
  ],
20
20
  "dependencies": {
21
- "@angular-devkit/core": "19.0.0-next.9",
21
+ "@angular-devkit/core": "19.0.0-rc.0",
22
22
  "jsonc-parser": "3.3.1",
23
- "magic-string": "0.30.11",
23
+ "magic-string": "0.30.12",
24
24
  "ora": "5.4.1",
25
25
  "rxjs": "7.8.1"
26
26
  },
package/src/rules/base.js CHANGED
@@ -46,8 +46,15 @@ function empty() {
46
46
  function chain(rules) {
47
47
  return async (initialTree, context) => {
48
48
  let intermediateTree;
49
- for await (const rule of rules) {
50
- intermediateTree = (0, call_1.callRule)(rule, intermediateTree ?? initialTree, context);
49
+ if (Symbol.asyncIterator in rules) {
50
+ for await (const rule of rules) {
51
+ intermediateTree = (0, call_1.callRule)(rule, intermediateTree ?? initialTree, context);
52
+ }
53
+ }
54
+ else {
55
+ for (const rule of rules) {
56
+ intermediateTree = (0, call_1.callRule)(rule, intermediateTree ?? initialTree, context);
57
+ }
51
58
  }
52
59
  return () => intermediateTree;
53
60
  };