1.0.5 • Published 5 months ago
wobe-graphql-apollo v1.0.5
What is Wobe apollo ?
Wobe apollo is a plugin for the wobe web framework that allows you to easily use the apollo server.
Install
bun install wobe-graphql-apollo # On bun
npm install wobe-graphql-apollo # On npm
yarn add wobe-graphql-apollo # On yarn
Basic example
import { Wobe } from 'wobe'
import { WobeGraphqlApolloPlugin } from 'wobe-graphql-apollo'
const wobe = new Wobe().usePlugin(
await WobeGraphqlApolloPlugin({
options: {
typeDefs: `
type Query {
hello: String
}
`,
resolvers: {
Query: {
hello: () => 'Hello from Apollo!',
},
},
},
}),
)
wobe.listen(3000)