- 
  Notifications
 You must be signed in to change notification settings 
- Fork 441
Create a schema with custom directives first change for #156 #1314
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First change for #156
Could you provide some grand vision/description of how it's supposed to work? And what would be the next steps?
From the provided example in the code and PR description, it's not very clear.
First change for #156
Could you provide some grand vision/description of how it's supposed to work? And what would be the next steps?
From the provided example in the code and PR description, it's not very clear.
Step 1: is allow custom directives, added to a schema to pass validation.
Step 2: Update graphql parser to support directive definitions
Step 3: Create a mechanisme for user code to react on directives during execution.
ed11cc0 to
 4e58054  
 Compare
 
 Step 3: Create a mechanisme for user code to react on directives during execution.
Could you sketch your vision of API?
37a5ec0 to
 6036544  
 Compare
 
 For the api, i have two idea's
- A visitor like pattern, on the the incoming query,
- Add a context like object as paramter to the fields.
Both i still need to reseach the code, on how to implement this in a non breaking way.
modified: juniper/src/schema/model.rs# modified: juniper/src/schema/translate/graphql_parser.rs Added new function to create a schema with custom directives Added doctest Added directives to be included in the schema output
4e58054 to
 46eee82  
 Compare
 
 
(feat) create schema with custom directives
First change for #156