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

[json_codable] support static fromJson #59579

Open
cedvdb opened this issue Nov 21, 2024 · 1 comment
Open

[json_codable] support static fromJson #59579

cedvdb opened this issue Nov 21, 2024 · 1 comment
Labels
area-pkg Used for miscellaneous pkg/ packages not associated with specific area- teams. pkg-json The json macro package type-enhancement A request for a change that isn't a bug

Comments

@cedvdb
Copy link
Contributor

cedvdb commented Nov 21, 2024

json_codable currently check if there is a constructor with fromJson, no check is made for a static method.

use case

In order to support override of a serialization method used for enums. This is a preliminary issue before adding enum support

@dart-github-bot
Copy link
Collaborator

Summary: Users request json_codable support for static fromJson methods. This allows overriding serialization for enums.

@dart-github-bot dart-github-bot added area-pkg Used for miscellaneous pkg/ packages not associated with specific area- teams. triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. type-enhancement A request for a change that isn't a bug labels Nov 21, 2024
@lrhn lrhn added pkg-json The json macro package and removed triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. labels Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-pkg Used for miscellaneous pkg/ packages not associated with specific area- teams. pkg-json The json macro package type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

3 participants