GRAPHQL SCHEMA REFERENCE
Your API, mapped with intent.
Explore a workspace schema generated by GraphQL-Markdown for YARD, documented next to the Ruby client that calls it: operations, types, relationships, and ready-to-run examples on one site.
type Project implements Node {
id: ID!
name: String!
status: ProjectStatus!
owner: User!
}
type Query {
projects(status: ProjectStatus):
ProjectConnection!
}
OPERATIONS
Queries, mutations, subscriptions
MODELS
Objects, inputs, unions, enums
RUBY
Client docs linked to the schema
Two references, one site
- The Ruby client (DemoApi::Client) is documented from its source with YARD tags, like any gem on RubyDoc.info.
- The GraphQL schema is documented by GraphQL-Markdown: one Markdown page per type and operation, rendered by YARD as extra files next to the Ruby classes.
YARD’s {file:...} links work both ways. DemoApi::Client#projects returns
the nodes of a
ProjectConnection, and
its documentation links to the
projects query it sends.
How it is built
npm run generateruns GraphQL-Markdown on the shared demo schema and writes Markdown pages todocs/graphql/.bundle exec yard docrenders the Ruby sources and the generated pages listed in.yardoptsintosite/, with the templates inyard/templates/.