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

fix: Add camelCased aliases to Pydantic models #436

Merged
merged 1 commit into from
Mar 12, 2024

Conversation

eric-nguyen-cs
Copy link
Contributor

What

Pydantic supports aliases: https://docs.pydantic.dev/latest/concepts/alias/
This is particularly useful to use camelCased variables on the frontend and the normal snake_cased variables in Python

Copy link
Contributor

@perierc perierc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

backend/openapi/openapi.json Show resolved Hide resolved
@eric-nguyen-cs eric-nguyen-cs merged commit d5d5944 into main Mar 12, 2024
9 checks passed
@eric-nguyen-cs eric-nguyen-cs deleted the ericn/add-aliases-to-pydantic-models branch March 12, 2024 20:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: No status
Development

Successfully merging this pull request may close these issues.

2 participants