Skip to content

Commit 20d2c7b

Browse files
authored
Add some options to UrlLoader (#2898)
* Add some options to UrlLoader * multipart response support * changeset' * Fix polyfill * Bump * Try to fix withCancel * Align versions
1 parent 1bb49c5 commit 20d2c7b

13 files changed

+192
-73
lines changed

.changeset/purple-crews-rush.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@graphql-tools/url-loader': minor
3+
---
4+
5+
feat(url-loader): multipart response support

.changeset/two-papayas-work.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@graphql-tools/utils': minor
3+
---
4+
5+
feat(utils): add withCancel

.changeset/weak-eagles-flow.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@graphql-tools/url-loader': minor
3+
---
4+
5+
feat(url-loader): ability to provide different subscriptionsEndpoint
6+
feat(url-loader): ability to provide headers factory that takes executionParams

packages/loaders/github/tests/schema-from-github.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ function normalize(doc: string): string {
2828
}
2929

3030
test('load schema from GitHub', async () => {
31-
let headers: Record<string, string> = {};
31+
let headers: Record<string, string | string[]> = {};
3232
let query: string;
3333
let variables: any;
3434
let operationName: string;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
declare module 'sync-fetch';
2-
declare module 'graphql-upload';
2+
declare module '@ardatan/eventsource';

packages/loaders/url/package.json

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,20 +28,23 @@
2828
"@types/extract-files": "8.1.0",
2929
"@types/eventsource": "1.1.5",
3030
"@types/ws": "7.4.2",
31+
"graphql-upload": "11.0.0",
3132
"mock-http": "1.1.0",
3233
"mock-socket": "9.0.3"
3334
},
3435
"dependencies": {
3536
"@graphql-tools/delegate": "^7.0.1",
36-
"@graphql-tools/utils": "^7.1.5",
37+
"@graphql-tools/utils": "^7.8.1",
3738
"@graphql-tools/wrap": "^7.0.4",
3839
"@types/websocket": "1.0.2",
40+
"abort-controller": "3.0.0",
3941
"cross-fetch": "3.1.4",
40-
"eventsource": "1.1.0",
42+
"@ardatan/eventsource": "1.1.2",
4143
"extract-files": "9.0.0",
4244
"form-data": "4.0.0",
43-
"graphql-upload": "^11.0.0",
4445
"graphql-ws": "^4.4.1",
46+
"lodash": "4.17.21",
47+
"meros": "1.1.4",
4548
"is-promise": "4.0.0",
4649
"isomorphic-ws": "4.0.1",
4750
"sse-z": "0.3.0",

0 commit comments

Comments
 (0)