Closed frankcollins3 closed 1 year ago
👍 localhost:5000/graphql 👎 localhost:3000/graphql
run it from the location of the graphQL schema, in this instance graphQL is within: /server: index.js
[5:33am]
the error tells you it expected the name but found {
addPokemon: {
type: PokemonType,
description: 'Add a pokemon',
args: {
// arg to run condition against. With a strict equality match
* * * name: { type: new GraphQLNonNull(GraphQLString) } * * *
},
resolve: (parent, args) => {
const newpokemon = { name: args.name }
pokemon.push(newpokemon)
return pokemon;
}
}
[9:12am]
no ' ' have to use " " double quotes in graphQL
[9:14am]
was working in another repo and was able to see the API schema defined by graphQL properties.