Guest User

Untitled

a guest
Mar 29th, 2018
280
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.62 KB | None | 0 0
  1. query{
  2. login(email:"test@test.com",password:"test@test.com")
  3.  
  4. }
  5.  
  6. import {
  7. GraphQLNonNull,
  8. GraphQLString,
  9. GraphQLBoolean,
  10.  
  11. } from 'graphql'
  12.  
  13.  
  14. const userQueries = {
  15. login: {
  16. type: GraphQLBoolean,
  17. args: {
  18. email: {
  19. type: new GraphQLNonNull(GraphQLString),
  20. },
  21. password: {
  22. type: new GraphQLNonNull(GraphQLString)
  23. }
  24. },
  25. resolve: async (source, { email, password }) => {
  26. console.log(email)
  27. console.log(password)
  28. Meteor.call('login', [{ user: { email: 'test@test.com' }, password: 'test@test.com' }], console.log)
  29. }
  30.  
  31. },
  32. };
  33.  
  34. export default userQueries
Add Comment
Please, Sign In to add comment