Add the GraphQL integration

Add the GraphQL integration

Generate API docs from your GraphQL schema with @fumadocs/graphql:

press.config.tsx
import { createGraphQL, graphqlPlugin } from "@fumapress/graphql";

const graphql = createGraphQL({
  input: [path.resolve("./schema.graphql")],
});

export default defineConfig({
  content: {
    docs: docs.toFumadocsSource(),
    graphql: await graphql.staticSource({ baseUrl: "/" }),
  },
}).plugins(graphqlPlugin({ server: graphql }));

Last updated on

On this page