-
-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: support exact control types in FormGroup and FormArray (#35)
* feature: support exact control types in FormGroup and FormArray Support generic type that contains the type of the controls, so it's possible to infer it properly. * fix(pr): form group controls type * fix: conflicts * fix: test Add explicit generic type to avoid type error in formGroup.spec.ts * fix(type): solve issue with union types Prevent distributive conditional types so ControlOfValue<boolean> is FormControl<boolean> and not FormControl<true> | FormControl<false> See microsoft/TypeScript#37279 * feat: deep-controls interface * feat: override group controls type * rename DeepControlsOf to ControlsOf as requested * Added the ability to override the default behavior of this type. * fix(types): remove flat controls interface * fix(test): stabilize tests * fix(test): stabilize tests * fix(conflict): resolve conflicts * fix(tests): fixed tests typing Seems to be like TypeScript needed a little help inferring some of the types. Co-authored-by: sharshuv-quotient <[email protected]>
- Loading branch information
Showing
12 changed files
with
516 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.