Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tck1/apollo-graphiql-playground
Apollo Server plugin for the GraphiQL Playground
https://github.com/tck1/apollo-graphiql-playground
apollo apollo-server graphiql graphql playground server
Last synced: about 2 months ago
JSON representation
Apollo Server plugin for the GraphiQL Playground
- Host: GitHub
- URL: https://github.com/tck1/apollo-graphiql-playground
- Owner: tcK1
- License: other
- Created: 2023-03-20T09:57:28.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-03T16:14:48.000Z (9 months ago)
- Last Synced: 2024-11-01T05:34:53.393Z (3 months ago)
- Topics: apollo, apollo-server, graphiql, graphql, playground, server
- Language: TypeScript
- Homepage:
- Size: 94.7 KB
- Stars: 3
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# `apollo-graphiql-playground`
[![npm](https://img.shields.io/npm/v/apollo-graphiql-playground)](https://www.npmjs.com/package/apollo-graphiql-playground)
Plugin for using [GraphiQL](https://github.com/graphql/graphiql) playground inside an [Apollo Server](https://github.com/apollographql/apollo-server).
## Example
```ts
import { ApolloServerPluginLandingPageGraphiQLPlayground } from 'apollo-graphiql-playground'const server = new ApolloServer({
plugins: [
ApolloServerPluginLandingPageGraphiQLPlayground({
shouldPersistHeaders: true,
})
],
})
```### Options
- `url?` (default: `/graphql`): Which URL should the playground should use.
- `shouldPersistHeaders?`: Toggles if the contents of the headers editor are persisted in storage.