-
Notifications
You must be signed in to change notification settings - Fork 915
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(experimental): support more scalar values in getDiscriminate…
…dUnionCodec (#2395) This PR changes the custom values supported by `getDiscriminatedUnionCodec` from: ```ts type DiscriminatorValue = number | string | symbol; ``` to: ```ts type DiscriminatorValue = bigint | boolean | number | string | null | undefined; ``` Note that: - We are dropping the `symbol` type since TypeScript doesn't make any distinctions between different symbols (i.e. `Symbol('A') | Symbol('B')` is typed as `symbol | symbol`). - These values are now consistent with the new `getLiteralUnionCodec`.
- Loading branch information
1 parent
288029a
commit 7f48706
Showing
4 changed files
with
13 additions
and
4 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