rwsdk 1.0.0-beta.56 → 1.0.0-beta.57

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -29,6 +29,11 @@ if (typeof window !== "undefined") {
29
29
  * @returns RPC client instance.
30
30
  */
31
31
  export const getSyncedStateClient = (endpoint = DEFAULT_SYNCED_STATE_PATH) => {
32
+ // Convert relative endpoint to absolute URL for environments like WKWebView
33
+ if (endpoint.startsWith("/") && typeof window !== "undefined") {
34
+ const protocol = window.location.protocol === "https:" ? "wss:" : "ws:";
35
+ endpoint = `${protocol}//${window.location.host}${endpoint}`;
36
+ }
32
37
  // Return existing client if already cached for this endpoint
33
38
  const existingClient = clientCache.get(endpoint);
34
39
  if (existingClient) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rwsdk",
3
- "version": "1.0.0-beta.56",
3
+ "version": "1.0.0-beta.57",
4
4
  "description": "Build fast, server-driven webapps on Cloudflare with SSR, RSC, and realtime",
5
5
  "type": "module",
6
6
  "bin": {
@@ -154,7 +154,7 @@
154
154
  "license": "MIT",
155
155
  "dependencies": {
156
156
  "@ast-grep/napi": "~0.41.0",
157
- "@cloudflare/workers-types": "~4.20260305.1",
157
+ "@cloudflare/workers-types": "~4.20260307.1",
158
158
  "@mdx-js/mdx": "~3.1.1",
159
159
  "@puppeteer/browsers": "~2.13.0",
160
160
  "@types/decompress": "~4.2.7",
@@ -193,22 +193,22 @@
193
193
  "vite-tsconfig-paths": "~6.1.1"
194
194
  },
195
195
  "peerDependencies": {
196
- "@cloudflare/vite-plugin": "^1.26.0",
196
+ "@cloudflare/vite-plugin": "^1.26.1",
197
197
  "capnweb": "~0.5.0",
198
198
  "react": ">=19.2.0-0 <19.3.0 || >=19.3.0-0 <20.0.0",
199
199
  "react-dom": ">=19.2.0-0 <19.3.0 || >=19.3.0-0 <20.0.0",
200
200
  "react-server-dom-webpack": ">=19.2.0-0 <19.3.0 || >=19.3.0-0 <20.0.0",
201
201
  "vite": "^6.2.6 || 7.x",
202
- "wrangler": "^4.70.0"
202
+ "wrangler": "^4.71.0"
203
203
  },
204
- "packageManager": "pnpm@10.28.2",
204
+ "packageManager": "pnpm@10.31.0",
205
205
  "devDependencies": {
206
- "@cloudflare/vite-plugin": "1.26.0",
206
+ "@cloudflare/vite-plugin": "1.26.1",
207
207
  "capnweb": "~0.5.0",
208
208
  "@types/debug": "~4.1.12",
209
209
  "@types/js-beautify": "~1.14.3",
210
210
  "@types/lodash": "~4.17.24",
211
- "@types/node": "~25.3.3",
211
+ "@types/node": "~25.3.5",
212
212
  "@types/proper-lockfile": "~4.1.4",
213
213
  "js-beautify": "~1.15.4",
214
214
  "semver": "~7.7.4",