How to use prefer_alias? #2938
Answered
by
JacobCoffee
danielniccoli
asked this question in
Q&A
-
The changelog shows:
How do I configure/enable this? Could someone help out with a code sample? |
Beta Was this translation helpful? Give feedback.
Answered by
JacobCoffee
Jan 2, 2024
Replies: 1 comment 3 replies
-
You can set this by doing something like pydantic_plugin = PydanticPlugin(prefer_alias=True)
app = Litestar(route_handlers=[...], plugins=[pydantic_plugin]) |
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
Alc-Alc
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can set this by doing something like