-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
remove dependency on global
#2268
Conversation
a proper working fix for #2155 this use of `global` will be removed for 2.0.x, it only remains for legacy support
🦋 Changeset detectedLatest commit: 5c4549f The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
The latest changes of this PR are available as canary in npm (based on the declared |
Codecov Report
@@ Coverage Diff @@
## main #2268 +/- ##
==========================================
- Coverage 65.70% 64.71% -1.00%
==========================================
Files 85 81 -4
Lines 5106 5314 +208
Branches 1631 1715 +84
==========================================
+ Hits 3355 3439 +84
- Misses 1747 1871 +124
Partials 4 4
Continue to review full report at Codecov.
|
@@ -640,7 +640,7 @@ export class GraphiQL extends React.Component<GraphiQLProps, GraphiQLState> { | |||
// Utility for keeping CodeMirror correctly sized. | |||
this.codeMirrorSizer = new CodeMirrorSizer(); | |||
|
|||
if (global !== undefined) { | |||
if (typeof global !== undefined) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typeof returns a string
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ohh right 😆
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://runkit.com/rikki/6245c7abad19050009c26c25 this is what we want
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we will get rid of this hacky interface soon, but we have to wait til 2.0.0, in fact we will be required to (thankfully!)
a proper working fix for #2155
this use of
global
will be removed for 2.0.x, it only remains for legacy support