Document a GraphQL API

后端 未结 5 1325
梦谈多话
梦谈多话 2021-02-02 05:02

With REST we can use Swagger, RAML or other technologies to document our API and generate an HTML documentation that our consumers can read without any need of interaction with

5条回答
  •  孤独总比滥情好
    2021-02-02 05:48

    It looks like there is now https://www.npmjs.com/package/graphql-docs

    Dynamically generated documentation explorer for GraphQL schemas. It aims to provide a better overview of a schema than GraphiQL, but without querying features.

    You can also generate a static documentation file based on a schema file or GraphQL endpoint:

    npm install -g graphql-docs
    graphql-docs-gen http://GRAPHQL_ENDPOINT documentation.html
    

提交回复
热议问题