From 8b3e2cbf8262ea6c22f1c7982e8e099c8e6895a6 Mon Sep 17 00:00:00 2001 From: REDDY PRASAD Date: Tue, 18 Dec 2018 19:51:44 +0530 Subject: [PATCH] Disable GraphQL playground in production --- api/apollo-server.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api/apollo-server.js b/api/apollo-server.js index ea1daf51bc..85975323db 100644 --- a/api/apollo-server.js +++ b/api/apollo-server.js @@ -93,7 +93,7 @@ const server = new ProtectedApolloServer({ }; }), }, - playground: { + playground: process.env.NODE_ENV !== 'production' && { settings: { 'editor.theme': 'light', }, @@ -109,6 +109,7 @@ const server = new ProtectedApolloServer({ }, ], }, + introspection: process.env.NODE_ENV !== 'production', maxFileSize: 25 * 1024 * 1024, // 25MB engine: false, tracing: false,