Localize a value of attribute #7378
-
[Option('i', "input", Required = true, HelpText = "My Help Text")]
public string Input { get; set; } Is there any solution to localize the string "My Help Text"? |
Beta Was this translation helpful? Give feedback.
Answered by
huoyaoyuan
Jul 26, 2023
Replies: 1 comment 2 replies
-
The common practice is to encode a key in attribute/code, then implement lookup from localized resource when displaying. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Attribute data can't be set via reflection. You can manually create the data structure parsed from attribute, or create a feature request about localization.