@ngx-formly/schematics 10.0.1 → 11.1.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/README.md +32 -165
- package/package.json +4 -4
- package/utils/ast.d.ts +1 -1
- package/utils/ast.js +9 -5
- package/utils/ast.js.map +1 -1
- package/utils/lib-versions.d.ts +2 -2
- package/utils/lib-versions.js +2 -2
package/README.md
CHANGED
|
@@ -1,180 +1,47 @@
|
|
|
1
|
-
|
|
2
|
-
<a href="https://formly.dev">
|
|
3
|
-
<img width="200" src="https://raw.githubusercontent.com/ngx-formly/ngx-formly/v5/logo.svg?sanitize=true" />
|
|
4
|
-
</a>
|
|
5
|
-
<br />
|
|
6
|
-
JSON powered / Dynamic forms in Angular
|
|
7
|
-
<br /><br />
|
|
1
|
+
# @ngx-formly/schematics
|
|
8
2
|
|
|
9
|
-
|
|
10
|
-
[](https://npmjs.org/package/@ngx-formly/core)
|
|
11
|
-
[](https://gitter.im/formly-js/ng2-formly)
|
|
12
|
-
[](https://github.com/ngx-formly/ngx-formly/actions/workflows/ci.yml/badge.svg?branch=main)
|
|
13
|
-
[](https://twitter.com/formlydev)
|
|
14
|
-
[](https://gitpod.io/#https://github.com/ngx-formly/ngx-formly)
|
|
15
|
-
</div>
|
|
3
|
+
Angular CLI schematics for adding Formly to an NgModule application. The `ng-add` schematic installs Formly dependencies and adds the Formly and Reactive Forms imports to the application module.
|
|
16
4
|
|
|
17
|
-
|
|
5
|
+
Formly 11 targets Angular 22 or newer. For a standalone application, configure Formly manually using the [core package instructions](https://www.npmjs.com/package/@ngx-formly/core) and your UI adapter's README. This schematic expects an NgModule to update.
|
|
18
6
|
|
|
19
|
-
|
|
7
|
+
## Usage
|
|
20
8
|
|
|
21
|
-
|
|
9
|
+
Run this in your Angular workspace:
|
|
22
10
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
- Formly Schema (core)
|
|
27
|
-
- JSON Schema
|
|
28
|
-
- JSON Schema string defaults are configurable. See [schema defaults](docs/json-schema.md#defaults).
|
|
29
|
-
- 😍 A bunch of themes, out of the box!
|
|
30
|
-
- 💪 Built on top of [Angular Reactive Forms](https://angular.dev/guide/forms/reactive-forms)
|
|
31
|
-
- Nullable JSON Schema numbers preserve `null` when cleared. See [JSON Schema](docs/json-schema.md#nullable-numbers).
|
|
32
|
-
- Forms emit their initial validation status after building, including valid forms. See [form notifications](docs/properties-options.md#initial-validation-status).
|
|
33
|
-
- Subscribe to controls after fields load with the `fieldChange` output. See [form build notifications](docs/properties-options.md#accessing-controls-after-a-build).
|
|
34
|
-
- 📹 [@eggheadio course](https://egghead.io/playlists/configuration-based-reactive-angular-forms-with-ngx-formly-465f) - 20 lessons & 78 minutes
|
|
11
|
+
```sh
|
|
12
|
+
ng add @ngx-formly/schematics@^11 --ui-theme=bootstrap
|
|
13
|
+
```
|
|
35
14
|
|
|
36
|
-
|
|
15
|
+
Replace `bootstrap` with `material`, `ionic`, `primeng`, `kendo`, `ng-zorro-antd`, or `nativescript`. Omit `--ui-theme` if you plan to register your own field types.
|
|
37
16
|
|
|
38
|
-
|
|
39
|
-
Use the search button or Cmd/Ctrl+K to search guide and migration text, plus UI and example page names.
|
|
17
|
+
For a workspace with multiple projects, specify the target:
|
|
40
18
|
|
|
41
|
-
|
|
42
|
-
-
|
|
43
|
-
|
|
44
|
-
- [Ionic select interface options](docs/properties-options.md#ionic-select-interfaces)
|
|
45
|
-
- [Examples](https://formly.dev/examples)
|
|
19
|
+
```sh
|
|
20
|
+
ng add @ngx-formly/schematics@^11 --project=my-app --ui-theme=material
|
|
21
|
+
```
|
|
46
22
|
|
|
47
|
-
##
|
|
23
|
+
## What it changes
|
|
48
24
|
|
|
49
|
-
-
|
|
50
|
-
-
|
|
51
|
-
-
|
|
25
|
+
- Adds `@angular/forms` and `@ngx-formly/core` to `package.json` and schedules dependency installation.
|
|
26
|
+
- Imports `ReactiveFormsModule` and `FormlyModule.forRoot()` into the application module.
|
|
27
|
+
- When `--ui-theme` is set, adds the matching `@ngx-formly/<theme>` dependency and imports its Formly module.
|
|
52
28
|
|
|
53
|
-
|
|
29
|
+
Complete the UI library's setup, including its dependencies, global styles, and providers. The schematic does not configure those or create a form component.
|
|
54
30
|
|
|
55
|
-
|
|
56
|
-
| ------------------------------------------------- | ------------------------------------------------------------ | ----------------------------------------------------------------- |
|
|
57
|
-
| [Bootstrap](https://getbootstrap.com) | [Demo](https://formly.dev/ui/bootstrap) | [StackBlitz](https://stackblitz.com/edit/ngx-formly-ui-bootstrap) |
|
|
58
|
-
| [Material2](https://github.com/angular/material2) | [Demo](https://formly.dev/ui/material) | [StackBlitz](https://stackblitz.com/edit/ngx-formly-ui-material) |
|
|
59
|
-
| [Ionic](https://ionicframework.com) | [Demo](https://formly.dev/ui/ionic) | [StackBlitz](https://stackblitz.com/edit/ngx-formly-ui-ionic) |
|
|
60
|
-
| [PrimeNG](http://primefaces.org/primeng/#/) | [Demo](https://formly.dev/ui/primeng) | [StackBlitz](https://stackblitz.com/edit/ngx-formly-ui-primeng) |
|
|
61
|
-
| [Kendo](http://www.telerik.com/kendo-angular-ui) | [Demo](https://formly.dev/ui/kendo) | [StackBlitz](https://stackblitz.com/edit/ngx-formly-ui-kendo) |
|
|
62
|
-
| [NG-ZORRO](http://ng.ant.design) | [Demo](https://formly.dev/ui/ng-zorro-antd) | [StackBlitz](https://stackblitz.com/edit/ngx-formly-ui-ng-zorro-antd) |
|
|
63
|
-
| [NativeScript](https://www.nativescript.org) | ||
|
|
31
|
+
## UI setup guides
|
|
64
32
|
|
|
65
|
-
|
|
33
|
+
| Theme | Package instructions |
|
|
34
|
+
| --------------- | ------------------------------------------------------------------------------------ |
|
|
35
|
+
| `bootstrap` | [@ngx-formly/bootstrap](https://www.npmjs.com/package/@ngx-formly/bootstrap) |
|
|
36
|
+
| `material` | [@ngx-formly/material](https://www.npmjs.com/package/@ngx-formly/material) |
|
|
37
|
+
| `ionic` | [@ngx-formly/ionic](https://www.npmjs.com/package/@ngx-formly/ionic) |
|
|
38
|
+
| `primeng` | [@ngx-formly/primeng](https://www.npmjs.com/package/@ngx-formly/primeng) |
|
|
39
|
+
| `kendo` | [@ngx-formly/kendo](https://www.npmjs.com/package/@ngx-formly/kendo) |
|
|
40
|
+
| `ng-zorro-antd` | [@ngx-formly/ng-zorro-antd](https://www.npmjs.com/package/@ngx-formly/ng-zorro-antd) |
|
|
41
|
+
| `nativescript` | [@ngx-formly/nativescript](https://www.npmjs.com/package/@ngx-formly/nativescript) |
|
|
66
42
|
|
|
67
|
-
|
|
68
|
-
| --------------- | -------------------- | ---------------------------------- |
|
|
69
|
-
| Angular >= 21 | `@ngx-formly/core@10.x` | [Upgrade to v10](UPGRADE-10.0.md) |
|
|
70
|
-
| Angular >= 20 | `@ngx-formly/core@9.x` | [Upgrade to v9](UPGRADE-9.0.md) |
|
|
71
|
-
| Angular >= 19 | `@ngx-formly/core@8.x` | [Upgrade to v8](UPGRADE-8.0.md) |
|
|
72
|
-
| Angular >= 18 | `@ngx-formly/core@7.x` | [Upgrade to v7](UPGRADE-7.0.md) |
|
|
73
|
-
| Angular >= 13 | `@ngx-formly/core@6.x` | [Upgrade to v6](UPGRADE-6.0.md) |
|
|
74
|
-
| Angular >= 7 | `@ngx-formly/core@5.x` | [Upgrade to v5](UPGRADE-5.0.md) |
|
|
75
|
-
| Angular >= 6 | `@ngx-formly/core@4.x` | |
|
|
76
|
-
| Angular >= 5 | `@ngx-formly/core@3.x` | |
|
|
77
|
-
| Angular >= 4 | `@ngx-formly/core@2.x` | [Upgrade to v2](UPGRADE-2.0.md) |
|
|
78
|
-
| Angular >= 2 | `ng-formly@1.x` | |
|
|
43
|
+
## Documentation
|
|
79
44
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
`@ngx-formly/*` packages used by your application together to v10.
|
|
84
|
-
The Material, PrimeNG, and NG-ZORRO integrations require version 21 or newer of
|
|
85
|
-
their respective UI libraries. Kendo requires version 21.4.1 or newer, and NativeScript
|
|
86
|
-
requires `@nativescript/angular` 21 or newer. Applications staying on Angular 20 should use Formly v9.
|
|
87
|
-
|
|
88
|
-
See the [v10 upgrade guide](UPGRADE-10.0.md) for migration steps.
|
|
89
|
-
|
|
90
|
-
#### Upgrading to v9
|
|
91
|
-
|
|
92
|
-
Formly v9 requires Angular 20 or newer. Upgrade Angular first, then update all
|
|
93
|
-
`@ngx-formly/*` packages used by your application together to v9.
|
|
94
|
-
The Material, PrimeNG, and NG-ZORRO integrations require version 20 or newer of
|
|
95
|
-
their respective UI libraries. Kendo requires version 19.1 or newer, and NativeScript
|
|
96
|
-
requires `@nativescript/angular` 20 or newer. Applications staying on Angular 19 should
|
|
97
|
-
use Formly v8; applications staying on Angular 18 should use Formly v7.
|
|
98
|
-
|
|
99
|
-
PrimeNG datepicker fields no longer accept `monthNavigator`, `yearNavigator`, or
|
|
100
|
-
`yearRange`, which PrimeNG 20 removed. Replace `@primeng/themes` imports with
|
|
101
|
-
`@primeuix/themes` when configuring a PrimeNG theme.
|
|
102
|
-
|
|
103
|
-
See the [v9 upgrade guide](UPGRADE-9.0.md) for migration steps and the [changelog](CHANGELOG.md) for the full list of changes.
|
|
104
|
-
|
|
105
|
-
## Core Team
|
|
106
|
-
|
|
107
|
-
<table>
|
|
108
|
-
<tr>
|
|
109
|
-
<td align="center">
|
|
110
|
-
<a href="https://github.com/aitboudad">
|
|
111
|
-
<img src="https://avatars.githubusercontent.com/u/1753742?v=3" width="100px;" />
|
|
112
|
-
<br />
|
|
113
|
-
<sub><b>Abdellatif Ait boudad</b></sub>
|
|
114
|
-
</a>
|
|
115
|
-
</td>
|
|
116
|
-
<td align="center">
|
|
117
|
-
<a href="https://juri.dev">
|
|
118
|
-
<img src="https://avatars.githubusercontent.com/u/542458" width="100px;" />
|
|
119
|
-
<br />
|
|
120
|
-
<sub><b>Juri Strumpflohner</b></sub>
|
|
121
|
-
</a>
|
|
122
|
-
</td>
|
|
123
|
-
<td align="center">
|
|
124
|
-
<a href="https://github.com/mohammedzamakhan">
|
|
125
|
-
<img src="https://avatars.githubusercontent.com/u/2327532" width="100px;" />
|
|
126
|
-
<br />
|
|
127
|
-
<sub><b>Mohammed Zama Khan</b></sub>
|
|
128
|
-
</a>
|
|
129
|
-
</td>
|
|
130
|
-
<td align="center">
|
|
131
|
-
<a href="https://github.com/beeman">
|
|
132
|
-
<img src="https://avatars.githubusercontent.com/u/36491" width="100px;" />
|
|
133
|
-
<br />
|
|
134
|
-
<sub><b>Bram Borggreve</b></sub>
|
|
135
|
-
</a>
|
|
136
|
-
</td>
|
|
137
|
-
<td align="center">
|
|
138
|
-
<a href="https://github.com/kenisteward">
|
|
139
|
-
<img src="https://avatars.githubusercontent.com/u/12831669" width="100px;" />
|
|
140
|
-
<br />
|
|
141
|
-
<sub><b>Keni Steward</b></sub>
|
|
142
|
-
</a>
|
|
143
|
-
</td>
|
|
144
|
-
<td align="center">
|
|
145
|
-
<a href="https://github.com/MaxKless">
|
|
146
|
-
<img src="https://avatars.githubusercontent.com/u/34165455" width="100px;" />
|
|
147
|
-
<br />
|
|
148
|
-
<sub><b>Max Kless</b></sub>
|
|
149
|
-
</a>
|
|
150
|
-
</td>
|
|
151
|
-
</tr>
|
|
152
|
-
</table>
|
|
153
|
-
|
|
154
|
-
## Contributors
|
|
155
|
-
|
|
156
|
-
Thanks goes to these wonderful people:
|
|
157
|
-
|
|
158
|
-
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
|
|
159
|
-
[<img alt="aitboudad" src="https://avatars.githubusercontent.com/u/1753742?v=4&s=80" width="80"/>](https://github.com/aitboudad)[<img alt="mohammedzamakhan" src="https://avatars.githubusercontent.com/u/2327532?v=4&s=80" width="80"/>](https://github.com/mohammedzamakhan)[<img alt="divyakumarjain" src="https://avatars.githubusercontent.com/u/2039134?v=4&s=80" width="80"/>](https://github.com/divyakumarjain)[<img alt="MaxKless" src="https://avatars.githubusercontent.com/u/34165455?v=4&s=80" width="80"/>](https://github.com/MaxKless)[<img alt="couzic" src="https://avatars.githubusercontent.com/u/1380322?v=4&s=80" width="80"/>](https://github.com/couzic)[<img alt="juristr" src="https://avatars.githubusercontent.com/u/542458?v=4&s=80" width="80"/>](https://github.com/juristr)[<img alt="franzeal" src="https://avatars.githubusercontent.com/u/7455769?v=4&s=80" width="80"/>](https://github.com/franzeal)[<img alt="beeman" src="https://avatars.githubusercontent.com/u/36491?v=4&s=80" width="80"/>](https://github.com/beeman)
|
|
160
|
-
|
|
161
|
-
[<img alt="kenisteward" src="https://avatars.githubusercontent.com/u/12831669?v=4&s=80" width="80"/>](https://github.com/kenisteward)[<img alt="thorgod" src="https://avatars.githubusercontent.com/u/13910170?v=4&s=80" width="80"/>](https://github.com/thorgod)[<img alt="samtsai" src="https://avatars.githubusercontent.com/u/225526?v=4&s=80" width="80"/>](https://github.com/samtsai)[<img alt="luizfbicalho" src="https://avatars.githubusercontent.com/u/16882855?v=4&s=80" width="80"/>](https://github.com/luizfbicalho)[<img alt="klemenoslaj" src="https://avatars.githubusercontent.com/u/7548247?v=4&s=80" width="80"/>](https://github.com/klemenoslaj)[<img alt="FritzHerbers" src="https://avatars.githubusercontent.com/u/10029682?v=4&s=80" width="80"/>](https://github.com/FritzHerbers)[<img alt="dev-kanishk" src="https://avatars.githubusercontent.com/u/48204976?v=4&s=80" width="80"/>](https://github.com/dev-kanishk)[<img alt="vstiebe" src="https://avatars.githubusercontent.com/u/13326475?v=4&s=80" width="80"/>](https://github.com/vstiebe)
|
|
162
|
-
|
|
163
|
-
[<img alt="rpw1" src="https://avatars.githubusercontent.com/u/47835461?v=4&s=80" width="80"/>](https://github.com/rpw1)[<img alt="Devqon" src="https://avatars.githubusercontent.com/u/9316480?v=4&s=80" width="80"/>](https://github.com/Devqon)[<img alt="ryanjerskine" src="https://avatars.githubusercontent.com/u/5464778?v=4&s=80" width="80"/>](https://github.com/ryanjerskine)[<img alt="rehleinBo" src="https://avatars.githubusercontent.com/u/7338819?v=4&s=80" width="80"/>](https://github.com/rehleinBo)[<img alt="MarcosEllys" src="https://avatars.githubusercontent.com/u/6751242?v=4&s=80" width="80"/>](https://github.com/MarcosEllys)[<img alt="manuelmeister" src="https://avatars.githubusercontent.com/u/3001985?v=4&s=80" width="80"/>](https://github.com/manuelmeister)[<img alt="dolphinigle" src="https://avatars.githubusercontent.com/u/7020472?v=4&s=80" width="80"/>](https://github.com/dolphinigle)[<img alt="Lehoczky" src="https://avatars.githubusercontent.com/u/31937175?v=4&s=80" width="80"/>](https://github.com/Lehoczky)
|
|
164
|
-
|
|
165
|
-
[<img alt="Krustie101" src="https://avatars.githubusercontent.com/u/1636728?v=4&s=80" width="80"/>](https://github.com/Krustie101)[<img alt="intellix" src="https://avatars.githubusercontent.com/u/1162531?v=4&s=80" width="80"/>](https://github.com/intellix)[<img alt="skrtheboss" src="https://avatars.githubusercontent.com/u/10209728?v=4&s=80" width="80"/>](https://github.com/skrtheboss)[<img alt="dwaldrum" src="https://avatars.githubusercontent.com/u/386721?v=4&s=80" width="80"/>](https://github.com/dwaldrum)[<img alt="json-derulo" src="https://avatars.githubusercontent.com/u/18580672?v=4&s=80" width="80"/>](https://github.com/json-derulo)[<img alt="atsjo" src="https://avatars.githubusercontent.com/u/16601899?v=4&s=80" width="80"/>](https://github.com/atsjo)[<img alt="Cselt" src="https://avatars.githubusercontent.com/u/11027521?v=4&s=80" width="80"/>](https://github.com/Cselt)[<img alt="blowsie" src="https://avatars.githubusercontent.com/u/308572?v=4&s=80" width="80"/>](https://github.com/blowsie)
|
|
166
|
-
|
|
167
|
-
[<img alt="roshan-sama" src="https://avatars.githubusercontent.com/u/31125563?v=4&s=80" width="80"/>](https://github.com/roshan-sama)[<img alt="rternavskyi" src="https://avatars.githubusercontent.com/u/26190424?v=4&s=80" width="80"/>](https://github.com/rternavskyi)[<img alt="milasevicius" src="https://avatars.githubusercontent.com/u/1790265?v=4&s=80" width="80"/>](https://github.com/milasevicius)[<img alt="13dante04" src="https://avatars.githubusercontent.com/u/25120620?v=4&s=80" width="80"/>](https://github.com/13dante04)[<img alt="Riron" src="https://avatars.githubusercontent.com/u/5145523?v=4&s=80" width="80"/>](https://github.com/Riron)[<img alt="rbalet" src="https://avatars.githubusercontent.com/u/44493964?v=4&s=80" width="80"/>](https://github.com/rbalet)[<img alt="rafaelss95" src="https://avatars.githubusercontent.com/u/11965907?v=4&s=80" width="80"/>](https://github.com/rafaelss95)[<img alt="rammba" src="https://avatars.githubusercontent.com/u/40705899?v=4&s=80" width="80"/>](https://github.com/rammba)
|
|
168
|
-
|
|
169
|
-
[<img alt="Pouja" src="https://avatars.githubusercontent.com/u/2385144?v=4&s=80" width="80"/>](https://github.com/Pouja)[<img alt="OmkarJ13" src="https://avatars.githubusercontent.com/u/65808188?v=4&s=80" width="80"/>](https://github.com/OmkarJ13)[<img alt="NanFengCheong" src="https://avatars.githubusercontent.com/u/7321833?v=4&s=80" width="80"/>](https://github.com/NanFengCheong)[<img alt="Tom-V" src="https://avatars.githubusercontent.com/u/322654?v=4&s=80" width="80"/>](https://github.com/Tom-V)[<img alt="VyacheslavPritykin" src="https://avatars.githubusercontent.com/u/819457?v=4&s=80" width="80"/>](https://github.com/VyacheslavPritykin)[<img alt="akamyshanov" src="https://avatars.githubusercontent.com/u/1358330?v=4&s=80" width="80"/>](https://github.com/akamyshanov)[<img alt="danielcrisp" src="https://avatars.githubusercontent.com/u/1104814?v=4&s=80" width="80"/>](https://github.com/danielcrisp)[<img alt="francisco-sanchez-molina" src="https://avatars.githubusercontent.com/u/9049706?v=4&s=80" width="80"/>](https://github.com/francisco-sanchez-molina)
|
|
170
|
-
|
|
171
|
-
[<img alt="jazpearson" src="https://avatars.githubusercontent.com/u/7648154?v=4&s=80" width="80"/>](https://github.com/jazpearson)[<img alt="kapsiR" src="https://avatars.githubusercontent.com/u/7165033?v=4&s=80" width="80"/>](https://github.com/kapsiR)[<img alt="marfer" src="https://avatars.githubusercontent.com/u/1127166?v=4&s=80" width="80"/>](https://github.com/marfer)[<img alt="mburger81" src="https://avatars.githubusercontent.com/u/3778892?v=4&s=80" width="80"/>](https://github.com/mburger81)[<img alt="n3xus" src="https://avatars.githubusercontent.com/u/510213?v=4&s=80" width="80"/>](https://github.com/n3xus)[<img alt="neminovno" src="https://avatars.githubusercontent.com/u/1468887?v=4&s=80" width="80"/>](https://github.com/neminovno)[<img alt="sesidhar01" src="https://avatars.githubusercontent.com/u/61068911?v=4&s=80" width="80"/>](https://github.com/sesidhar01)[<img alt="vezzoo" src="https://avatars.githubusercontent.com/u/28898894?v=4&s=80" width="80"/>](https://github.com/vezzoo)
|
|
172
|
-
|
|
173
|
-
[<img alt="wenqi73" src="https://avatars.githubusercontent.com/u/23337087?v=4&s=80" width="80"/>](https://github.com/wenqi73)[<img alt="yoni333" src="https://avatars.githubusercontent.com/u/19931760?v=4&s=80" width="80"/>](https://github.com/yoni333)[<img alt="AlexTalcura" src="https://avatars.githubusercontent.com/u/20095773?v=4&s=80" width="80"/>](https://github.com/AlexTalcura)[<img alt="alex-novikov-1990" src="https://avatars.githubusercontent.com/u/6377930?v=4&s=80" width="80"/>](https://github.com/alex-novikov-1990)[<img alt="alvarolb" src="https://avatars.githubusercontent.com/u/1141353?v=4&s=80" width="80"/>](https://github.com/alvarolb)[<img alt="andmoredev" src="https://avatars.githubusercontent.com/u/33256364?v=4&s=80" width="80"/>](https://github.com/andmoredev)[<img alt="vitale232" src="https://avatars.githubusercontent.com/u/8504254?v=4&s=80" width="80"/>](https://github.com/vitale232)[<img alt="AmGarera" src="https://avatars.githubusercontent.com/u/6021169?v=4&s=80" width="80"/>](https://github.com/AmGarera)
|
|
174
|
-
|
|
175
|
-
[<img alt="atsjo" src="https://avatars.githubusercontent.com/u/16601899?v=4&s=80" width="80"/>](https://github.com/atsjo)[<img alt="bhaidar" src="https://avatars.githubusercontent.com/u/1163421?v=4&s=80" width="80"/>](https://github.com/bhaidar)[<img alt="cyrilletuzi" src="https://avatars.githubusercontent.com/u/555867?v=4&s=80" width="80"/>](https://github.com/cyrilletuzi)[<img alt="json-derulo" src="https://avatars.githubusercontent.com/u/18580672?v=4&s=80" width="80"/>](https://github.com/json-derulo)[<img alt="Dayvisson" src="https://avatars.githubusercontent.com/u/12189515?v=4&s=80" width="80"/>](https://github.com/Dayvisson)[<img alt="dereekb" src="https://avatars.githubusercontent.com/u/3586580?v=4&s=80" width="80"/>](https://github.com/dereekb)[<img alt="eduardoRoth" src="https://avatars.githubusercontent.com/u/5419161?v=4&s=80" width="80"/>](https://github.com/eduardoRoth)[<img alt="enricouniurb" src="https://avatars.githubusercontent.com/u/38656571?v=4&s=80" width="80"/>](https://github.com/enricouniurb)
|
|
176
|
-
|
|
177
|
-
[<img alt="erikvdv1" src="https://avatars.githubusercontent.com/u/2014802?v=4&s=80" width="80"/>](https://github.com/erikvdv1)[<img alt="fynnfeldpausch" src="https://avatars.githubusercontent.com/u/1246913?v=4&s=80" width="80"/>](https://github.com/fynnfeldpausch)[<img alt="jrgleason" src="https://avatars.githubusercontent.com/u/1319151?v=4&s=80" width="80"/>](https://github.com/jrgleason)[<img alt="johannesjo" src="https://avatars.githubusercontent.com/u/1456265?v=4&s=80" width="80"/>](https://github.com/johannesjo)[<img alt="johndbell" src="https://avatars.githubusercontent.com/u/1931322?v=4&s=80" width="80"/>](https://github.com/johndbell)[<img alt="jdpnielsen" src="https://avatars.githubusercontent.com/u/8746698?v=4&s=80" width="80"/>](https://github.com/jdpnielsen)[<img alt="TheMcMurder" src="https://avatars.githubusercontent.com/u/3059715?v=4&s=80" width="80"/>](https://github.com/TheMcMurder)[<img alt="LennardWesterveld" src="https://avatars.githubusercontent.com/u/1076589?v=4&s=80" width="80"/>](https://github.com/LennardWesterveld)
|
|
178
|
-
|
|
179
|
-
[<img alt="logvinoleg89" src="https://avatars.githubusercontent.com/u/12018303?v=4&s=80" width="80"/>](https://github.com/logvinoleg89)[<img alt="LucasJAlba" src="https://avatars.githubusercontent.com/u/2780076?v=4&s=80" width="80"/>](https://github.com/LucasJAlba)[<img alt="lucienbertin" src="https://avatars.githubusercontent.com/u/10089239?v=4&s=80" width="80"/>](https://github.com/lucienbertin)[<img alt="luizbicalhoagl" src="https://avatars.githubusercontent.com/u/93284446?v=4&s=80" width="80"/>](https://github.com/luizbicalhoagl)[<img alt="waffle-iron" src="https://avatars.githubusercontent.com/u/6912981?v=4&s=80" width="80"/>](https://github.com/waffle-iron)[<img alt="mathijshoogland" src="https://avatars.githubusercontent.com/u/7372934?v=4&s=80" width="80"/>](https://github.com/mathijshoogland)[<img alt="mrbusche" src="https://avatars.githubusercontent.com/u/792378?v=4&s=80" width="80"/>](https://github.com/mrbusche)[<img alt="mehranmb78" src="https://avatars.githubusercontent.com/u/144687844?v=4&s=80" width="80"/>](https://github.com/mehranmb78)
|
|
180
|
-
<!-- ALL-CONTRIBUTORS-LIST:END -->
|
|
45
|
+
- [Formly guide](https://formly.dev/guide)
|
|
46
|
+
- [Upgrade to Formly 11](https://github.com/ngx-formly/ngx-formly/blob/main/UPGRADE-11.0.md)
|
|
47
|
+
- [Source](https://github.com/ngx-formly/ngx-formly/tree/main/src/schematics)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ngx-formly/schematics",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "11.1.0-rc.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "tsc -p tsconfig.lib.json"
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
"save": "devDependencies"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@angular-devkit/core": "^
|
|
14
|
-
"@angular-devkit/schematics": "^
|
|
15
|
-
"@schematics/angular": "^
|
|
13
|
+
"@angular-devkit/core": "^22.2.2",
|
|
14
|
+
"@angular-devkit/schematics": "^22.2.2",
|
|
15
|
+
"@schematics/angular": "^22.2.2"
|
|
16
16
|
},
|
|
17
17
|
"homepage": "https://github.com/ngx-formly/ngx-formly#readme",
|
|
18
18
|
"description": "Formly is a dynamic (JSON powered) form library for Angular that bring unmatched maintainability to your application's forms.",
|
package/utils/ast.d.ts
CHANGED
|
@@ -18,6 +18,6 @@ export declare function getIndexHtmlPath(host: Tree, project: WorkspaceProject):
|
|
|
18
18
|
/** Get the root stylesheet file. */
|
|
19
19
|
export declare function getStylesPath(host: Tree, project: WorkspaceProject): string;
|
|
20
20
|
/** Wraps the internal find module from options with undefined path handling */
|
|
21
|
-
export declare function findModuleFromOptions(host: Tree, options: ComponentOptions): Promise<string
|
|
21
|
+
export declare function findModuleFromOptions(host: Tree, options: ComponentOptions): Promise<string>;
|
|
22
22
|
export declare function getProjectMainFile(project: workspaces.ProjectDefinition): Path;
|
|
23
23
|
export declare function getProjectTargetOptions(project: workspaces.ProjectDefinition, buildTarget: string): Record<string, JsonValue | undefined>;
|
package/utils/ast.js
CHANGED
|
@@ -82,16 +82,16 @@ function addModuleImportToRootModule(host, moduleName, src, project) {
|
|
|
82
82
|
}
|
|
83
83
|
/** Gets the app index.html file */
|
|
84
84
|
function getIndexHtmlPath(host, project) {
|
|
85
|
-
const buildTarget = project.architect
|
|
86
|
-
if (buildTarget
|
|
85
|
+
const buildTarget = project.architect?.build?.options;
|
|
86
|
+
if (buildTarget?.index && buildTarget.index.endsWith('index.html')) {
|
|
87
87
|
return buildTarget.index;
|
|
88
88
|
}
|
|
89
89
|
throw new schematics_1.SchematicsException('No index.html file was found.');
|
|
90
90
|
}
|
|
91
91
|
/** Get the root stylesheet file. */
|
|
92
92
|
function getStylesPath(host, project) {
|
|
93
|
-
const buildTarget = project.architect['build'];
|
|
94
|
-
if (buildTarget
|
|
93
|
+
const buildTarget = project.architect?.['build'];
|
|
94
|
+
if (buildTarget?.options?.styles?.length) {
|
|
95
95
|
const styles = buildTarget.options.styles.map(s => typeof s === 'string' ? s : s.input);
|
|
96
96
|
// First, see if any of the assets is called "styles.(le|sc|c)ss", which is the default
|
|
97
97
|
// "main" style sheet.
|
|
@@ -117,7 +117,11 @@ async function findModuleFromOptions(host, options) {
|
|
|
117
117
|
if (options.path === undefined) {
|
|
118
118
|
options.path = `/${project.root}/src/app`;
|
|
119
119
|
}
|
|
120
|
-
|
|
120
|
+
const modulePath = (0, find_module_1.findModuleFromOptions)(host, options);
|
|
121
|
+
if (!modulePath) {
|
|
122
|
+
throw new schematics_1.SchematicsException('Could not find an NgModule to configure Formly.');
|
|
123
|
+
}
|
|
124
|
+
return modulePath;
|
|
121
125
|
}
|
|
122
126
|
function getProjectMainFile(project) {
|
|
123
127
|
const buildOptions = getProjectTargetOptions(project, 'build');
|
package/utils/ast.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ast.js","sourceRoot":"","sources":["ast.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiBH,0DAsBC;AAGD,0CAMC;AAGD,kEAGC;AAGD,4CAQC;AAGD,sCAqBC;AAGD,
|
|
1
|
+
{"version":3,"file":"ast.js","sourceRoot":"","sources":["ast.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiBH,0DAsBC;AAGD,0CAMC;AAGD,kEAGC;AAGD,4CAQC;AAGD,sCAqBC;AAGD,sDAqBC;AAED,gDAWC;AAED,0DAaC;AA3ID,+CAAiD;AACjD,2DAAuE;AACvE,+CAAiC;AACjC,2EAA4E;AAC5E,yEAAsG;AAEtG,qEAAqE;AAKrE,qEAAwE;AACxE,+DAAgE;AAEhE,sFAAsF;AACtF,SAAgB,uBAAuB,CACrC,IAAU,EACV,UAAkB,EAClB,UAAkB,EAClB,GAAW;IAEX,MAAM,YAAY,GAAG,eAAe,CAAC,IAAI,EAAE,UAAU,CAAC,CAAC;IAEvD,IAAI,CAAC,YAAY,EAAE,CAAC;QAClB,MAAM,IAAI,gCAAmB,CAAC,qBAAqB,UAAU,EAAE,CAAC,CAAC;IACnE,C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,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
|
package/utils/lib-versions.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const angularVersion = "^
|
|
2
|
-
export declare const ngxFormlyVersion = "^
|
|
1
|
+
export declare const angularVersion = "^22.0.0";
|
|
2
|
+
export declare const ngxFormlyVersion = "^11.0.0";
|
package/utils/lib-versions.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ngxFormlyVersion = exports.angularVersion = void 0;
|
|
4
|
-
exports.angularVersion = '^
|
|
5
|
-
exports.ngxFormlyVersion = '^
|
|
4
|
+
exports.angularVersion = '^22.0.0';
|
|
5
|
+
exports.ngxFormlyVersion = '^11.0.0';
|
|
6
6
|
//# sourceMappingURL=lib-versions.js.map
|