Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .changeset/pre.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,19 @@
"form-aria-busy",
"fs-eager-components",
"fs-emission-adapter",
"hash-history-typed-paths",
"is-routing-native-pops",
"late-bound-server-function-codec",
"lazy-before-leave",
"lazy-paths-proxy",
"lazy-route-subtrees",
"link-state-collector-instance",
"live-query-channel-prototype",
"metadata-detection-for-get",
"navigate-url-semantics",
"own-single-flight-and-nojs",
"popular-pears-boil",
"preserve-layouts-between-child-routes",
"query-implies-get",
"query-redirect-revalidate-pending",
"redirect-sweep-retained-sections",
Expand All @@ -60,6 +63,7 @@
"update-solid-beta-7",
"update-solid-rc-0",
"update-solid-rc-1",
"update-solid-rc-3",
"warn-nested-router-mounts"
]
}
47 changes: 47 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,52 @@
# @solidjs/router

## 2.0.0-next.18

### Patch Changes

- 5b9ffb2: Fix navigation and redirects with typed paths under hashHistory (#582). Paths nodes now carry their logical path under the global `Href` brand (`Symbol.for("solid.Href")`): `navigate()` routes the logical path directly instead of coercing the node to its display href, and `redirect(paths()...)` no longer throws `@solidjs/web`'s Href guard. Display-form strings (terminated paths calls, redirect Location headers) starting with `#` are mapped back through the history integration's parser, the same way anchor clicks are. Plain string arguments remain logical paths and are never parsed.
- c81606b: `liveQuery()` — keyed live queries over value-shaped streams (prototype)

Declares a keyed live query: an async-iterable producer whose yields are
successive values of one logical query, re-yielding current state on every
invocation. liveQuery IS the live declaration — no separate wrapper needed:
server functions are declared GET at creation (like `query`), the server
face brands the resolved iterable so SSR live policy applies (document face
renders the first value, hydration adopts it and reconnects), and the
client channel owns reconnect-with-backoff when a connected stream dies.

One connection per (name + args) key is shared by every consumer: late
subscribers receive the latest value immediately, delivery is latest-wins,
and the connection closes when the last consumer leaves (microtask linger
so a re-running memo doesn't thrash it). Connections are lazy — calling the
function returns a live-branded iterable; the first pull connects — so
hydration traces open nothing. Retry is for transient deaths only: a
definite rejection (4xx — the transport stamps HTTP statuses onto
failures) ends the channel and surfaces the error to consumers, like a
first-connect failure does. On the server, channels are request-scoped:
every consumer of a key within one render observes the same first value
(the record is retained past teardown for replay), and separate requests
never share connections. Calling under preload intent warms the channel
(a temporary hold spans the preload window), so navigation renders against
an already-connected stream instead of holding the transition on connect
plus first yield.

Live queries participate in both router data protocols. Explicit
`revalidate(key)` reconnects (the producer re-yields current state on
invocation). Single-flight participation is delivery-side: a mutation's
flight payload pushes straight into open channels — the mutation response
is the round trip — while the post-mutation sweep leaves the healthy
connection in place, since the live stream is itself the freshness
mechanism. New `registerRevalidateHook`/`registerFlightDataHook` seams in
query let keyed stores join those protocols without coupling.

The callable carries the `query` conventions (`key`, `keyFor`) plus a
reactive `status(...args)` read ("idle" | "connecting" | "connected" |
"reconnecting" | "closed").

- 0484065: fix #588: preserve nested route layouts between sibling navigations
- 29e08ad: Update to solid-js 2.0.0-rc.3 and raise the peer floor to `^2.0.0-rc.3`. rc.3 deprecates reactive writes during SSR (`[SERVER_WRITE]`), and the router's one server-side signal write — the lazy-subtree version bump — now keeps its count in plain module state on the server (the client still mirrors it into a signal for subscription), so server renders stay warning-free and ready for when the deprecation becomes an error.

## 2.0.0-next.17

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"Ryan Turnquist"
],
"license": "MIT",
"version": "2.0.0-next.17",
"version": "2.0.0-next.18",
"homepage": "https://github.com/solidjs/solid-router#readme",
"repository": {
"type": "git",
Expand Down