UNPKG

930 BJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3exports.ApolloServerPluginLandingPageGraphQLPlayground = void 0;
4const graphql_playground_html_1 = require("@apollographql/graphql-playground-html");
5const defaultPlaygroundVersion = '1.7.42';
6function ApolloServerPluginLandingPageGraphQLPlayground(options = Object.create(null)) {
7 return {
8 async serverWillStart() {
9 return {
10 async renderLandingPage() {
11 return {
12 html: (0, graphql_playground_html_1.renderPlaygroundPage)({
13 version: defaultPlaygroundVersion,
14 ...options,
15 }),
16 };
17 },
18 };
19 },
20 };
21}
22exports.ApolloServerPluginLandingPageGraphQLPlayground = ApolloServerPluginLandingPageGraphQLPlayground;
23//# sourceMappingURL=index.js.map
\No newline at end of file