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

feat: Allow ignoring fields from embedded structs #499

Merged
merged 1 commit into from
Feb 17, 2025

Conversation

camh-
Copy link
Contributor

@camh- camh- commented Feb 14, 2025

If a field in a struct is ignored with kong:"-", any embedded fields
with the same name are also ignored. This allows an outer struct to
remove flags from an embedded struct by redefining it and adding a kong
ignore tag.

@camh- camh- marked this pull request as draft February 14, 2025 21:51
If a field in a struct is ignored with `kong:"-"`, any embedded fields
with the same name are also ignored. This allows an outer struct to
remove flags from an embedded struct by redefining it and adding a kong
ignore tag.
@camh- camh- marked this pull request as ready for review February 17, 2025 03:57
@alecthomas
Copy link
Owner

Nice, thanks Cam :)

@alecthomas alecthomas merged commit 300cba8 into alecthomas:master Feb 17, 2025
5 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