Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
handleUI (context, options = {}) {
Object.assign(this.$options, options)
return graphiqlAdonis({
...this.$options,
})(context)
}
}
handleUi (context) {
return graphiqlAdonis({
endpointURL: '/'
})(context)
}
}
handle (context, options = {}) {
if (!this.$schema) {
throw new Error('Schema has not been defined')
}
if (options.mocks) {
addMockFunctionsToSchema({
schema: this.$schema,
preserveResolvers: false
})
}
return graphqlAdonis({
context,
schema: this.$schema
})(context)
}
handle (context, options = {}) {
Object.assign(this.$options, options)
return graphqlAdonis({
context,
schema: this.$schema,
formatError: this.$handleError,
...this.$options,
})(context)
}