Are there queries for Enums in Prisma?
# prisma-whats-new
w
Are there queries for Enums in Prisma?
l
Wish I had a better answer. https://cl.ly/131u240a3b3e Obviously there's a way to parse it from an introspection query, but that may be more trouble than it's worth
w
Copy + Paste it is 🙂
are enums just strings on the client?
d
personally I am using graphql-code-generator to help with that
l
Yes they're strings on the client
d
with Typescript I get a real enums with that generator, no strings, works really great
n
I don't understand your initial question, @wesbos. Can you elaborate?
l
We're looking for a way to expose an enum list to the client.
The answer is over a year old 🙂 But should point you in the right direction.
I would argue a hardcoded list in your Yoga server might be the better approach.
parrotwave6 1