Skip to content

Commit 656e7ad

Browse files
committed
chore(deps): update all dependencies
1 parent a2ba4f8 commit 656e7ad

File tree

5 files changed

+3535
-4350
lines changed

5 files changed

+3535
-4350
lines changed

package.json

Lines changed: 28 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,17 @@
1111
"build-fixtures": "npm run update-schema && npm run relay-compiler",
1212
"lint": "eslint src test",
1313
"prepublish": "npm run build",
14-
"relay-compiler": "relay-compiler --watchman false --src test --schema test/fixtures/schema.graphql",
14+
"relay-compiler": "relay-compiler",
1515
"tdd": "jest --watch",
1616
"test": "npm run build-fixtures && npm run lint && npm run testonly -- --coverage",
1717
"testonly": "jest --runInBand --verbose",
1818
"update-schema": "babel-node test/fixtures/updateSchema.js"
1919
},
20+
"relay": {
21+
"src": "./test",
22+
"schema": "./test/fixtures/schema.graphql",
23+
"language": "javascript"
24+
},
2025
"husky": {
2126
"hooks": {
2227
"pre-commit": "lint-staged"
@@ -55,28 +60,28 @@
5560
"relay-runtime": ">=1.0.0"
5661
},
5762
"devDependencies": {
58-
"@4c/babel-preset": "^7.4.1",
59-
"@babel/cli": "^7.14.5",
60-
"@babel/core": "^7.14.6",
61-
"@babel/node": "^7.14.7",
62-
"babel-jest": "^26.6.3",
63+
"@4c/babel-preset": "^10.2.1",
64+
"@babel/cli": "^7.23.9",
65+
"@babel/core": "^7.23.9",
66+
"@babel/node": "^7.23.9",
67+
"babel-jest": "^29.7.0",
6368
"babel-plugin-add-module-exports": "^1.0.4",
64-
"babel-plugin-relay": "^10.1.3",
65-
"codecov": "^3.8.2",
66-
"eslint": "^7.29.0",
67-
"eslint-config-4catalyzer": "^1.2.0",
68-
"eslint-config-4catalyzer-jest": "^2.1.0",
69-
"eslint-config-prettier": "^6.15.0",
70-
"eslint-plugin-import": "^2.23.4",
71-
"eslint-plugin-jest": "^23.20.0",
72-
"eslint-plugin-prettier": "^3.4.0",
73-
"graphql": "^15.5.1",
74-
"graphql-relay": "^0.7.0",
75-
"husky": "^4.3.8",
76-
"jest": "^26.6.3",
77-
"lint-staged": "^10.5.4",
78-
"prettier": "^2.3.2",
79-
"relay-compiler": "^10.1.3",
80-
"relay-runtime": "^10.1.3"
69+
"babel-plugin-relay": "^16.2.0",
70+
"codecov": "^3.8.3",
71+
"eslint": "^8.56.0",
72+
"eslint-config-4catalyzer": "^1.5.0",
73+
"eslint-config-4catalyzer-jest": "^2.3.0",
74+
"eslint-config-prettier": "^9.1.0",
75+
"eslint-plugin-import": "^2.29.1",
76+
"eslint-plugin-jest": "^27.6.3",
77+
"eslint-plugin-prettier": "^5.1.3",
78+
"graphql": "^16",
79+
"graphql-relay": "^0.10.0",
80+
"husky": "^4",
81+
"jest": "^29.7.0",
82+
"lint-staged": "^15.2.0",
83+
"prettier": "^3.2.4",
84+
"relay-compiler": "^16.2.0",
85+
"relay-runtime": "^16.2.0"
8186
}
8287
}

src/createFetch.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
import { graphql } from 'graphql';
22

33
export default function createFetch({ schema, rootValue, contextValue }) {
4-
return function fetchQuery(operation, variables) {
5-
return graphql(
4+
return function fetchQuery(operation, variableValues) {
5+
return graphql({
66
schema,
7-
operation.text,
7+
source: operation.text,
88
rootValue,
99
contextValue,
10-
variables,
11-
).then((payload) => {
10+
variableValues,
11+
}).then((payload) => {
1212
if (payload.errors) {
13-
throw new Error(payload.errors);
13+
throw new Error(payload.errors.join('\n'));
1414
}
1515

1616
return payload;

test/Network.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ import {
77
graphql,
88
} from 'relay-runtime';
99

10-
import { Network } from '../src';
1110
import schema, { resetData } from './fixtures/schema';
11+
import { Network } from '../src';
1212

1313
function executeQuery(environment, taggedNode) {
1414
const query = getRequest(taggedNode);

test/fixtures/schema.graphql

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,3 @@
1-
type Mutation {
2-
setWidgetName(input: SetWidgetNameInput!): SetWidgetNamePayload
3-
}
4-
5-
"""An object with an ID"""
6-
interface Node {
7-
"""The id of the object."""
8-
id: ID!
9-
}
10-
111
type Query {
122
"""Fetches an object given its ID"""
133
node(
@@ -24,18 +14,28 @@ type Query {
2414
invalid: Widget
2515
}
2616

27-
input SetWidgetNameInput {
28-
name: String!
29-
clientMutationId: String
30-
}
31-
32-
type SetWidgetNamePayload {
33-
widget: Widget
34-
clientMutationId: String
17+
"""An object with an ID"""
18+
interface Node {
19+
"""The id of the object."""
20+
id: ID!
3521
}
3622

3723
type Widget implements Node {
3824
"""The ID of an object"""
3925
id: ID!
4026
name: String
4127
}
28+
29+
type Mutation {
30+
setWidgetName(input: SetWidgetNameInput!): SetWidgetNamePayload
31+
}
32+
33+
type SetWidgetNamePayload {
34+
widget: Widget
35+
clientMutationId: String
36+
}
37+
38+
input SetWidgetNameInput {
39+
name: String!
40+
clientMutationId: String
41+
}

0 commit comments

Comments
 (0)