-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
add uuid type #2751
add uuid type #2751
Conversation
Ok, so this is just like PR #2749 but here the choice is github.com/google/uuid instead of there it is github.com/gofrs/uuid Many people will have already chosen one of those two (or something else) and so will have: models:
UUID:
model:
- github.com/gofrs/uuid.UUID Please add an example that uses this to verify that people can still override the default choice. |
UUID typeadd to gqlgen.yalm models:
UUID:
model:
- github.com/99designs/gqlgen/graphql.UUID add UUID scalar to schema.graphqls scalar UUID See the _examples/uuid package for more examples. |
add example in _examples/uuid and modify scalar doc (docs/content/reference/scalar.md) |
ok, thank you! |
Is there anything else that needs to be improved or revised? |
Signed-off-by: Steve Coffman <steve@khanacademy.org>
Thanks for your patience. I was quite ill for a while, and I'm only now getting caught up at my day job so I can return to gqlgen. I added a commit that used the documentation from #2749 here (thanks!) and I'm merging this one. |
Is it better to return the |
A Universally Unique Identifier (UUID) is a 128-bit used for information in computer systems. The term Globally Unique Identifier (GUID) is also used, mostly in Microsoft systems.
Because Go (still) does not have built-in support for UUID types, module
google/uuid
is imported. It's one of the most complete, correct (and starred) modules nowadays (the other beinggithub.com/gofrs/uuid.UUID
).This pull request introduces support for Universally Unique Identifiers (UUID) within
gqlgen
.Many people may have already chosen a different UUID library: