Skip to content

Commit 40c624e

Browse files
committed
do not require graphql
1 parent 1ab5ed7 commit 40c624e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

graphql.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@
170170
if (typeof query == 'object' && query.hasOwnProperty('kind') && query.hasOwnProperty('definitions')) {
171171
// This looks like a graphql AST.
172172
try {
173-
var graphql = require('graphql')
173+
var graphql = eval('require(\'graphql\')') // webpack tries to include this
174174
query = graphql.print(query)
175175
} catch (e) {
176176
throw new Error("You tried to pass a graphql syntax tree but it cannot be compiled to string.")

graphql.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)