nilan
02/24/2017, 11:28 AMartyom
02/24/2017, 5:09 PMric0
02/24/2017, 5:17 PMmartin
02/24/2017, 7:18 PMemail
in the User
Model? Is that even possible?tim2
02/24/2017, 10:25 PMwallslide
02/25/2017, 2:25 AMnilan
02/25/2017, 9:50 AMartyom
02/25/2017, 1:06 PMcharles
02/25/2017, 11:38 PMartyom
02/26/2017, 11:43 AMzimme
02/26/2017, 11:44 AMartyom
02/26/2017, 11:44 AMvetekrans
02/26/2017, 11:58 AMrobdonn
02/26/2017, 12:16 PMartyom
02/26/2017, 5:09 PMrubenabix
02/26/2017, 5:09 PMartyom
02/26/2017, 10:50 PMchandu0101
02/26/2017, 11:19 PMmarciobueno1
02/27/2017, 4:59 AMfalconerd
02/27/2017, 5:12 AMnilan
02/27/2017, 7:27 AMric0
02/27/2017, 11:30 AMtype Example {
_id: String!
description: String
length: String
}
type Query {
listExamples: [Example]
}
type Mutation {
insertExample(description: String): Example
}
schema {
query: Query
mutation: Mutation
}
//In my resolvers
Mutation: {
insertExample(_, {description}): {
const exampleId = Examples.insert({
description: description,
length: description.length
})
return Examples.findOne(exampleId)
}
},
Query; {
listExample(_){
Examples.find({}).fetch()
}
},
Example({length}) {
const info = length > 25 ? 'LONG' : 'SHORT'
return info
}
Is this possible in graphcool?yorunohikage
02/27/2017, 1:11 PMgopidon
02/27/2017, 4:52 PMartyom
02/27/2017, 7:37 PMejoebstl
02/27/2017, 9:36 PMfalconerd
02/27/2017, 9:38 PMeliecerthoms
02/28/2017, 1:07 AMmeglio
02/28/2017, 5:13 AMmeglio
02/28/2017, 5:15 AM