Skip to content

Commit

Permalink
upgrade example to 0.20.0
Browse files Browse the repository at this point in the history
  • Loading branch information
zth committed May 15, 2021
1 parent 19052b3 commit 05e045c
Show file tree
Hide file tree
Showing 5 changed files with 56 additions and 43 deletions.
21 changes: 10 additions & 11 deletions example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,34 +4,33 @@
"description": "",
"main": "index.html",
"scripts": {
"start": "yarn bs:clean && yarn bs:build && concurrently \"yarn relay:watch\" \"yarn webpack\" \"yarn bs:watch\"",
"bs:build": "bsb -make-world",
"bs:watch": "bsb -make-world -w",
"bs:clean": "bsb -clean-world",
"start": "concurrently \"yarn relay:watch\" \"yarn webpack\" \"yarn res:watch\"",
"res": "rescript build -with-deps",
"res:watch": "yarn res -w",
"webpack": "webpack-dev-server",
"relay": "rescript-relay-compiler",
"relay:watch": "rescript-relay-compiler --watch"
},
"dependencies": {
"@mdi/font": "3.7.95",
"@rescript/react": "0.10.1",
"bootstrap": "^4.3.1",
"bs-fetch": "^0.5.0",
"concurrently": "^5.0.0",
"graphql": "^14.5.8",
"react": "0.0.0-experimental-4e08fb10c",
"react-dom": "0.0.0-experimental-4e08fb10c",
"react-relay": "11.0.0",
"react-relay": "11.0.2",
"reason-promise": "^1.1.1",
"@rescript/react": "0.10.1",
"rescript-relay": "0.18.2",
"relay-compiler": "11.0.0",
"relay-config": "11.0.0",
"relay-runtime": "11.0.0",
"relay-compiler": "11.0.2",
"relay-config": "11.0.2",
"relay-runtime": "11.0.2",
"rescript-relay": "0.20.0",
"subscriptions-transport-ws": "^0.9.18"
},
"devDependencies": {
"bs-platform": "9.0.2",
"html-webpack-plugin": "^3.2.0",
"rescript": "^9.1.2",
"webpack": "^4.41.2",
"webpack-cli": "^3.3.9",
"webpack-dev-server": "^3.9.0"
Expand Down
4 changes: 2 additions & 2 deletions example/src/RelayEnv.res
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ let subscriptionFunction: RescriptRelay.Network.subscribeFn = (config, variables
}

RescriptRelay.Observable.make(sink => {
let observable = subscriptionClient["request"](subscriptionQuery)
let subscription = observable["subscribe"](sink)
let observable = subscriptionClient["request"](. subscriptionQuery)
let subscription = observable["subscribe"](. sink)
Some(subscription)
})
}
Expand Down
5 changes: 2 additions & 3 deletions example/src/SubscriptionsTransportWs.res
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,10 @@ type operationOptions = {
}

type observable<'a> = {
@meth
"subscribe": RescriptRelay.Observable.sink<'a> => RescriptRelay.Observable.subscription,
"subscribe": (. RescriptRelay.Observable.sink<'a>) => RescriptRelay.Observable.subscription,
}

type t<'a> = {@meth "request": operationOptions => observable<'a>}
type t<'a> = {"request": (. operationOptions) => observable<'a>}

@new @module("subscriptions-transport-ws")
external createSubscriptionClient: (string, 'a) => t<'b> = "SubscriptionClient"
Expand Down
4 changes: 4 additions & 0 deletions example/src/__generated__/MainQuery_graphql.res

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

65 changes: 38 additions & 27 deletions example/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1076,11 +1076,6 @@ bs-fetch@^0.5.0:
resolved "https://registry.yarnpkg.com/bs-fetch/-/bs-fetch-0.5.2.tgz#a9f4582ddb1414d3467b900305c738813481988c"
integrity sha512-CYweTJcgLeLOqzR3vNsB+NmyEFhWThnPNdZmmF28nkFmo0CQEf+20eSHZJDO6EuAhhoRqJ0qp2VgxtH6zBB5xA==

[email protected]:
version "9.0.2"
resolved "https://registry.yarnpkg.com/bs-platform/-/bs-platform-9.0.2.tgz#a6eac70eb8924a322556dacaccbfbc9b2a0d3a37"
integrity sha512-Ye9JqJ4Oa7mcjjoOVRYI8Uc2Cf8N7jQLWDcdUplY7996d/YErSR7WitmV7XnSwr4EvdrbwjEsg1NxNjUQv3ChA==

[email protected]:
version "2.1.1"
resolved "https://registry.yarnpkg.com/bser/-/bser-2.1.1.tgz#e6787da20ece9d07998533cfd9de6f5c38f4bc05"
Expand Down Expand Up @@ -2686,6 +2681,13 @@ interpret@^1.4.0:
resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.4.0.tgz#665ab8bc4da27a774a40584e812e3e0fa45b1a1e"
integrity sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==

invariant@^2.2.4:
version "2.2.4"
resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6"
integrity sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==
dependencies:
loose-envify "^1.0.0"

ip-regex@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/ip-regex/-/ip-regex-2.1.0.tgz#fa78bf5d2e6913c911ce9f819ee5146bb6d844e9"
Expand Down Expand Up @@ -3885,15 +3887,16 @@ [email protected]:
object-assign "^4.1.1"
scheduler "0.0.0-experimental-4e08fb10c"

[email protected].0:
version "11.0.0"
resolved "https://registry.yarnpkg.com/react-relay/-/react-relay-11.0.0.tgz#385b629198596a1d1e7879e9c3577cf9e6b6b697"
integrity sha512-6ehR4ADbbJzA4slrEkL3iNBNIpICrBUBx3/kKZJN9JMfVKnXeOV52KmryIV1wj8yJU+wbkueu4h05fdQLTAIhw==
[email protected].2:
version "11.0.2"
resolved "https://registry.yarnpkg.com/react-relay/-/react-relay-11.0.2.tgz#5f77e30e0d592f19c641e5dcc42f5d828bd16da5"
integrity sha512-RxtLBl8nxbaP26RcNDtKMrUBuJB5kFCCI4aZxnZByoncgovDgtewAsMiwcI8aDA8FjmXWRAtAAckh8DkMsMp7Q==
dependencies:
"@babel/runtime" "^7.0.0"
fbjs "^3.0.0"
invariant "^2.2.4"
nullthrows "^1.1.1"
relay-runtime "11.0.0"
relay-runtime "11.0.2"

[email protected]:
version "0.0.0-experimental-4e08fb10c"
Expand Down Expand Up @@ -3981,10 +3984,10 @@ [email protected]:
resolved "https://registry.yarnpkg.com/relateurl/-/relateurl-0.2.7.tgz#54dbf377e51440aca90a4cd274600d3ff2d888a9"
integrity sha1-VNvzd+UUQKypCkzSdGANP/LYiKk=

[email protected].0:
version "11.0.0"
resolved "https://registry.yarnpkg.com/relay-compiler/-/relay-compiler-11.0.0.tgz#265bded552b0938ad597ea14b9488e3d818b99cf"
integrity sha512-xAVcnWBNtkIJqRwae2agY+riDhh00bV/HqwbcBYijK/S9jKPEFLx9FguGG1V8EWgS/barBsBMtE7CG916GtSrA==
[email protected].2:
version "11.0.2"
resolved "https://registry.yarnpkg.com/relay-compiler/-/relay-compiler-11.0.2.tgz#e1e09a1c881d169a7a524ead728ad6a89c7bd4af"
integrity sha512-nDVAURT1YncxSiDOKa39OiERkAr0DUcPmlHlg+C8zD+EiDo2Sgczf2R6cDsN4UcDvucYtkLlDLFErPwgLs8WzA==
dependencies:
"@babel/core" "^7.0.0"
"@babel/generator" "^7.5.0"
Expand All @@ -3998,25 +4001,27 @@ [email protected]:
fbjs "^3.0.0"
glob "^7.1.1"
immutable "~3.7.6"
invariant "^2.2.4"
nullthrows "^1.1.1"
relay-runtime "11.0.0"
relay-runtime "11.0.2"
signedsource "^1.0.0"
yargs "^15.3.1"

[email protected].0:
version "11.0.0"
resolved "https://registry.yarnpkg.com/relay-config/-/relay-config-11.0.0.tgz#ed9e46046119c5572651944f7da632384ea54522"
integrity sha512-oXqNGRU4TM1doZQfFFt+v95LRW4ohWuHfPc6ayyTuTKkafqqHOUWdxjpB+UD5JWPBR/xUsnyA7o0ypXceBuK0Q==
[email protected].2:
version "11.0.2"
resolved "https://registry.yarnpkg.com/relay-config/-/relay-config-11.0.2.tgz#d1e5bbac795dfe0a414ed61c94faabdef7db99c5"
integrity sha512-j/bl04lGwZ+xSM/21KN87lPXY6t7YWkStfST63dQhJN35F6gQKZevmxVVPlEJ7Qs41AyrY1kilGBIfbEZPPdSA==
dependencies:
cosmiconfig "^5.0.5"

[email protected].0:
version "11.0.0"
resolved "https://registry.yarnpkg.com/relay-runtime/-/relay-runtime-11.0.0.tgz#cb3244dc4e2919a51fdcbedddd5d13a20cf393e8"
integrity sha512-7oeyW4hulyK3p4eB63Rsllo/es83xflCAt2HMWCpH2q0fi21iJBR02kK3wCPM/yFwi3i0K83W+UksLFQdE0CaQ==
[email protected].2:
version "11.0.2"
resolved "https://registry.yarnpkg.com/relay-runtime/-/relay-runtime-11.0.2.tgz#c3650477d45665b9628b852b35f203e361ad55e8"
integrity sha512-xxZkIRnL8kNE1cxmwDXX8P+wSeWLR+0ACFyAiAhvfWWAyjXb+bhjJ2FSsRGlNYfkqaTNEuDqpnodQV1/fF7Idw==
dependencies:
"@babel/runtime" "^7.0.0"
fbjs "^3.0.0"
invariant "^2.2.4"

remove-trailing-separator@^1.0.1:
version "1.1.0"
Expand Down Expand Up @@ -4059,12 +4064,18 @@ requires-port@^1.0.0:
resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff"
integrity sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=

rescript-relay@0.18.2:
version "0.18.2"
resolved "https://registry.yarnpkg.com/rescript-relay/-/rescript-relay-0.18.2.tgz#feb129d6c5c49a72061f8fa3737bbc2710a8c63d"
integrity sha512-6vVObBpFapAEP8T2/XI3ggSlkpeYEFzwZQjJiCnZEhBU1XfAr0ECGcBAwLuTn0HgC9Z1cyEIZfM2UZIAj/4hZg==
rescript-relay@0.20.0:
version "0.20.0"
resolved "https://registry.yarnpkg.com/rescript-relay/-/rescript-relay-0.20.0.tgz#fad9944fd80524aee9c22328c389f359c9b3e81f"
integrity sha512-Lcy5ziyOP9kSNC8M5x7EQws824ZbzU15kpGbY23pwzHArbJwlzwb1LeAJAqBUgYJbrTBjeorp/lyVNImN8qxdw==
dependencies:
mkdirp-sync "^0.0.3"
rescript "^9.1.2"

rescript@^9.1.2:
version "9.1.2"
resolved "https://registry.yarnpkg.com/rescript/-/rescript-9.1.2.tgz#a81f8a735f1a7006233bfc72eb081ca7182a0d79"
integrity sha512-4wHvTDv3nyYnAPJHcg1RGG8z7u3HDiBf6RN3P/dITDv859Qo35aKOzJWQtfBzbAs0EKNafLqei3TnUqiAv6BwQ==

resolve-cwd@^2.0.0:
version "2.0.0"
Expand Down

0 comments on commit 05e045c

Please sign in to comment.