Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/badsyntax/gatsby-openapi
A mono-repo with a set a gatsby plugins that can be used to build API docs from an OpenAPI specification.
https://github.com/badsyntax/gatsby-openapi
gatsby openapi
Last synced: 25 days ago
JSON representation
A mono-repo with a set a gatsby plugins that can be used to build API docs from an OpenAPI specification.
- Host: GitHub
- URL: https://github.com/badsyntax/gatsby-openapi
- Owner: badsyntax
- Created: 2020-08-21T16:26:15.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-08-30T18:22:18.000Z (over 4 years ago)
- Last Synced: 2024-11-05T15:53:24.435Z (2 months ago)
- Topics: gatsby, openapi
- Language: TypeScript
- Homepage:
- Size: 3.59 MB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# gatsby-openapi
![Build and Deploy](https://github.com/badsyntax/gatsby-openapi/workflows/Build%20and%20Deploy/badge.svg)
A mono-repo with a set a gatsby plugins that can be used to build API docs from an OpenAPI specification.
__NOTE:__ This repo is in the very early stages of development.
## Plugins
- [gatsby-source-openapi](./packages/gatsby-source-openapi): Parse an OpenAPI 3 specification and create the gatsby graphql nodes.
- [gatsby-theme-openapi-core](./packages/gatsby-theme-openapi-core): Creates the theme pages.
- [gatsby-theme-openapi-theme-ui](./packages/gatsby-theme-openapi-theme-ui): Renders the OpenAPI docs using `theme-ui`.## Examples
- [example-theme-ui](./packages.example-theme-ui): An example site using the [gatsby-theme-openapi-theme-ui]('./packages/gatsby-theme-openapi-theme-ui) theme
## Goals
- Provide a framework for building API docs with full customisation capabilities (not just tweaking theme variables)
- Provide some good default themes
- Provide features to render in a single page, or multiple pages
- Provide a CLI utility to easily bootstrap/scaffold## Developing
This is a lerna project. Common dependencies are hoisted into the root `node_modules` directory. This means you must re-bootstrap the project (`npm run boostrap`) after installing any dependencies into any of the packages.
### Getting Started
```sh
# install lerna dependencies
npm install# install & hoist package dependencies (this can take a long time)
npm run bootstrap# run the example site
npm start
```### Build the example site
```sh
npm run build
```### Troubleshooting
`Error sourcing OpenAPI data: security.map(...).flat is not a function`
This usually means you're using an older version of node. Use the version as specified in `.nvmrc` or within `package.json`.
## License
MIT License
Copyright (c) 2020 Richard Willis