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

Add predicates to for built-in types. #924

Merged
merged 1 commit into from
Dec 4, 2017

Conversation

IvanGoncharov
Copy link
Member

I find myself copy-pasting the same list of built-in scalar names in every new project we start.
In many cases, built-in types/directives should be handled differently so having such simple predicates save a lot of code lines.

Because of circular dependencies, I couldn't figure out file suitable for builtInTypes and isBuiltInType. That's why I created a new one: src/type/builtins.js.
Is it an appropriate filename or should I put somewhere else?

@IvanGoncharov
Copy link
Member Author

rebased

@leebyron leebyron merged commit 9204271 into graphql:master Dec 4, 2017
@leebyron
Copy link
Contributor

leebyron commented Dec 4, 2017

I made some final edits - renaming a few things for consistency, but I really like this addition. Thanks @IvanGoncharov

@leebyron
Copy link
Contributor

leebyron commented Dec 4, 2017

See 134184e for the final edits

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants