Skip to content

Commit

Permalink
Improve and fix subscriptions implementation (#114)
Browse files Browse the repository at this point in the history
* Fix subscriptions

* update schema

* updates

* progress

* progress

* progress

* clean

* testing

* handle broadcast completed

* clear up async iterators of listeners

* rename deferred promise result

* changesets

* codegen preset changeset
  • Loading branch information
PabloSzx authored Oct 2, 2023
1 parent a9c7ddc commit 630de3a
Show file tree
Hide file tree
Showing 24 changed files with 8,441 additions and 3,290 deletions.
5 changes: 5 additions & 0 deletions .changeset/cold-flowers-hug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@soundxyz/graphql-react-query': patch
---

Bump expected peer dependencies
5 changes: 5 additions & 0 deletions .changeset/fast-vans-wink.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@soundxyz/graphql-react-ws': major
---

Make Valtio a peer dependency
5 changes: 5 additions & 0 deletions .changeset/polite-foxes-mate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@soundxyz/graphql-react-ws': patch
---

Subscriptions re-use underlying connections while also keeping separate listening instances and callbacks
5 changes: 5 additions & 0 deletions .changeset/smart-cows-wash.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@soundxyz/codegen-fragments': major
---

Bump for GraphQL Codegen v4
18 changes: 18 additions & 0 deletions examples/next/.graphqlrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,21 @@ extensions:
preset: '@soundxyz/codegen-fragments'
config:
enumsAsConst: true
scalars:
DateTime: 'string'
NonNegativeInt: 'number'
PositiveInt: 'number'
JSON: 'unknown'
Timestamp: 'number'
Void: 'null'
UUID: 'string'
Address: 'string'
CountryCode: 'string'
EmailAddress: 'string'
NonEmptyString: 'string'
URL: 'string'
ENS: 'string'
NonNegativeFloat: 'number'
JWT: 'string'
SemanticVersion: 'string'
TransactionHash: 'string'
1 change: 0 additions & 1 deletion examples/next/next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
experimental: {
appDir: true,
externalDir: true,
},
};
Expand Down
26 changes: 14 additions & 12 deletions examples/next/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,25 @@
"watch": "graphql-codegen --watch"
},
"dependencies": {
"@graphql-codegen/typescript": "^3.0.2",
"@graphql-typed-document-node/core": "^3.1.2",
"@graphql-codegen/typescript": "^4.0.1",
"@graphql-typed-document-node/core": "^3.2.0",
"@soundxyz/gql-string": "workspace:*",
"@soundxyz/graphql-react-query": "workspace:*"
"@soundxyz/graphql-react-query": "workspace:*",
"@soundxyz/graphql-react-ws": "workspace:^"
},
"devDependencies": {
"@graphql-codegen/cli": "^3.2.2",
"@graphql-codegen/core": "^3.1.0",
"@graphql-codegen/cli": "^5.0.0",
"@graphql-codegen/core": "^4.0.0",
"@parcel/watcher": "^2.3.0",
"@soundxyz/codegen-fragments": "workspace:*",
"@types/node": "^18.14.6",
"@types/react": "^18.0.28",
"@types/react-dom": "^18.0.11",
"concurrently": "^7.6.0",
"graphql": "^16.6.0",
"next": "^13.2.3",
"@types/node": "^20.8.0",
"@types/react": "^18.2.24",
"@types/react-dom": "^18.2.8",
"concurrently": "^8.2.1",
"graphql": "^16.8.1",
"next": "^13.5.3",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"typescript": "^4.9.5"
"typescript": "^5.2.2"
}
}
Loading

0 comments on commit 630de3a

Please sign in to comment.