Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(typings): correctly extract nested oprional form group array typing #181

Merged
merged 1 commit into from
Aug 15, 2023

Conversation

ntziolis
Copy link
Contributor

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

This PR addresses an edge case the previous PR #180 did not cover.

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

Assuming the current Formtype:

export interface FormType {
  items: {
    tags?: FormControl<string[] | null>
  }[]
}

When using ValuesOf<ControlsOf<FormType>>, tags has the type string[] | null instead of string[] | null | undefined.

Issue Number: N/A

What is the new behavior?

Does this PR introduce a breaking change?

[ ] Yes
[x] No

Other information

@stackblitz
Copy link

stackblitz bot commented Aug 14, 2023

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@ntziolis ntziolis marked this pull request as ready for review August 14, 2023 08:43
@ntziolis
Copy link
Contributor Author

ntziolis commented Aug 14, 2023

Apologies, this edge case slipped through in the last PR

@NetanelBasal NetanelBasal merged commit d60d618 into ngneat:master Aug 15, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants