Repository navigation
v0.1.39
Describe the validate() contract instead of naming the project behind it
Parity is shape, never product identity. Comment only.
docs: the preloads run AFTER the providers start, not before
Upstream's warm-up is providers.start() -> the 'starting' hooks -> the preloads.
These comments said the opposite and placed advice on it.
fix(assets): match If-None-Match as a list, not as a string
A strict === answered 200 for three shapes a real client sends: *, a
comma-separated list of tags, and the weak form W/"…". A browser holding the
exact bytes therefore downloaded them again — which is most of what a validator
exists to prevent, so the ETag was doing half its job.
RFC 9110 §13.1.2 semantics, written here rather than imported: aurora does not
depend on ream, where the same function already lives.
fix(assets): serve a validator, and stop caching page sources in dev
serveAssets emitted public, max-age=60 and no ETag or Last-Modified, and
pageAssetsHandler took that default. Page modules are SOURCE files in
development: an edited page was handed back stale for a minute, with no way for
the browser even to ask whether it had changed, and config/aurora.ts offered
no way to say otherwise.
Responses now carry an ETag and honour If-None-Match. Hashed from the bytes
being sent rather than from mtime and size: a checkout, a rebuild or a touched
file all move the metadata without changing the content, and each would
needlessly re-download.
AssetsRequest.header() is OPTIONAL, so a host that only implements param()
keeps working -- it simply gets no conditional requests, which is what happened
before.
Page assets are no-cache outside production. That does not mean "do not
cache": it means "always ask", and the ETag makes the question nearly free.
fix(render): run onMount for a component built by a later update
onMount hooks are collected into one queue while the tree is built and flushed
once, after the fragment is in the document. A reactive slot that swapped its
content AFTERWARDS kept appending to that same queue, and nothing flushed it
again: the component's setup ran, its onMount never did, and the hooks piled up
for the life of the page with nothing logged.
That is every row-scoped component in a table -- rows arrive from an RPC, so
each one is a later update. A menu built that way toggled its state and never
opened a panel, which is most of a floating layer.
The queue now carries whether it has been flushed, so a slot knows to run its
own hooks. It collects them apart either way, because the TEARDOWNS belong to
the slot: on the root's list a component mounted per row kept its subscription
until the whole page unmounted. During the initial pass it defers to the root's
flush, since the nodes are still in a detached fragment and an onMount that
measures or focuses must see a live one.
Changes since v0.1.38.