Skip to content

buildClientSchema: build enum type value maps lazily #4424

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

Open
wants to merge 1 commit into
base: next
Choose a base branch
from

Conversation

yaacovCR
Copy link
Contributor

@yaacovCR yaacovCR commented Jun 3, 2025

The option of passing a thunk was made available by: #4018 .

Always passing the thunk helps contribute to a "lazy" build process, which gives the following performance boost:

image

@yaacovCR yaacovCR requested a review from a team as a code owner June 3, 2025 18:07
This makes definition of enum values lazy similar to how field/input field definition is lazy. It brings a small performance improvement when using enums in large schemas, as the enum values are only defined when they are actually used
@yaacovCR yaacovCR force-pushed the build-enum-lazily branch from 31a3c51 to 41c044c Compare June 6, 2025 09:14
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.

1 participant