Skip to content

Conversation

@lbarthon
Copy link

This allows us to customize the enum value for string_enum. So far, only the case attribute was allowing us to customize the value of those variants, this is a next step in allowing the value to be different from the actual name.

This has a new test, and snapshots have been updated accordingly.

@Brooooooklyn - could we include that in napi v2 and tag after it?

This allows us to customize the enum value for string_enum. So far, only the
case attribute was allowing us to customize the value of those variants, this
is a next step in allowing the value to be different from the actual name.

This has a new test, and snapshots have been updated accordingly.
Copy link
Member

could we include that in napi v2 and tag after it?

sure

@Brooooooklyn Brooooooklyn merged commit c223954 into napi-rs:main May 17, 2024
richerfu pushed a commit to richerfu/napi-rs that referenced this pull request May 17, 2024
This allows us to customize the enum value for string_enum. So far, only the case attribute was allowing us to customize the value of those variants, this is a next step in allowing the value to be different from the actual name.

This has a new test, and snapshots have been updated accordingly.

@Brooooooklyn - could we include that in napi v2 and tag after it?
Brooooooklyn pushed a commit that referenced this pull request May 18, 2024
This allows us to customize the enum value for string_enum. So far, only the case attribute was allowing us to customize the value of those variants, this is a next step in allowing the value to be different from the actual name.

This has a new test, and snapshots have been updated accordingly.

@Brooooooklyn - could we include that in napi v2 and tag after it?
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