Releases: remorses/spiceflow
spiceflow@1.20.0-rsc.3
-
Preserved function and class names in build output — Spiceflow's Vite plugin now sets
keepNames: trueby default in Rollup output and the dependency optimizer, so function names survive minification for better stack traces and debugging. Explicit userkeepNamesconfig is still respected. -
Simplified context redirect typing —
context.redirect()in page and layout handlers now accepts plain strings, removing overly strict path validation that caused false type errors when redirecting to dynamic or external URLs. -
Standalone trace timing logged separately — the
nf3dependency tracing step now logs its own duration instead of including resolve time, giving clearer build performance visibility.
spiceflow@1.20.0-rsc.2
-
Fixed RSC federation corrupting multiline Flight payloads — federated async iterable payloads containing multiline strings or JSX no longer corrupt React's internal chunk state. Flight data is now relayed as JSON-encoded text chunks instead of splitting on newlines, preventing
chunk.reason.enqueueModelcrashes. -
Build logs aligned with Vite's logger style — prerender and standalone dependency tracing output now uses Vite's logger, respects log levels, and shows timed success summaries with dimmed relative paths. Removed
picocolorsruntime dependency in favor of vendored color helpers.
spiceflow@1.20.0-rsc.1
-
Router state commits with the navigation payload —
useRouterState()now defers client navigation updates until the matching RSC payload is ready, so components no longer observe the next URL with stale server-rendered content during transitions. -
Consistent base-path router state on the server — server-side
useRouterState()now returns the same base-path-strippedpathnameas the client router state, matching apps deployed under a non-root Vite base path.
spiceflow@1.20.0-rsc.0
-
Render JSX to static HTML inside RSC —
spiceflow/federationnow exportsrenderToStaticMarkup()for email HTML, previews, and other server-only markup that should not hydrate. React'srenderToStaticMarkupfromreact-dom/serverdoes not work in the React Server Components environment because RSC renders JSX to Flight first; Spiceflow's helper uses the same Flight-to-HTML bridge as federation:import { renderToStaticMarkup } from 'spiceflow/federation' const html = await renderToStaticMarkup( <section> <h1>Welcome, Ada</h1> <p>Your invite code is 1234.</p> </section>, )
spiceflow@1.19.0-rsc.9
-
router.href()results work with typed<Link>— links can now receive URLs produced byrouter.href()while raw stringhrefvalues still stay type-checked against registered routes:<Link href={router.href('/orgs/:orgId/projects/:projectId', { orgId, projectId })} />
spiceflow@1.19.0-rsc.8
-
Typed loader data in page and layout handlers —
loaderDatais now inferred inside.page(),.staticPage(), and.layout()handlers from every matching loader, including wildcard parent loaders. Shared route data can stay in loaders while server handlers read it directly without casts:export const app = new Spiceflow() .loader('/*', async () => ({ user: await getUser() })) .loader('/projects/:projectId', async ({ params }) => ({ projectId: params.projectId })) .page('/projects/:projectId', async ({ loaderData }) => { return <ProjectPage user={loaderData.user} projectId={loaderData.projectId} /> })
-
Fixed
SpiceflowRegistercircular inference with loader readers — apps can keep the global register pattern while client components read typed loader data withuseLoaderData('/path'). Rendering those components from a route handler no longer causes the app initializer to fall back toany. -
Documented string form actions — forms with a string
actionare documented as normal browser submissions that perform a full document navigation, while function actions keep React transition behavior.
spiceflow@1.19.0-rsc.10
-
Typed loader data stays inferred with registered routing APIs —
loaderData,useLoaderData(), androuter.getLoaderData()keep route-specific types when using theSpiceflowRegisterpattern, without page and layout components forcing circular app inference. -
Cleaner redirect typing from reusable UI code — the exported
redirect()helper now accepts string paths for shared code, while route handlers keep route-awarecontext.redirect()typing for app-specific redirects.
spiceflow@1.19.0-rsc.7
-
Fixed
require is not definedon Cloudflare Workers — explicitly include@vitejs/plugin-rscvendored react-server-dom CJS files incommonjsOptions.includefor the RSC build environment, preventing barerequire("react")calls from failing in worker environments. Also updates@vitejs/plugin-rscfrom 0.5.21 to 0.5.24. -
Fixed vite-rsc CSS loader comments — shared Spiceflow modules no longer contain the static
loadCsstoken in comments, avoiding non-RSC environment assertion flashes during Cloudflare development.
spiceflow@1.19.0-rsc.6
-
Vercel
waitUntilauto-detection — Spiceflow now auto-detects Vercel's request context (globalThis[Symbol.for('@vercel/request-context')]) forwaitUntil, forwarding background work to the Vercel execution context automatically. No configuration needed on Vercel deployments. -
Graceful shutdown tracks
waitUntilpromises —preventProcessExitIfBusymiddleware now waits for pendingwaitUntilpromises before exiting, not just in-flight requests. Prevents background work from being dropped during shutdown:import { preventProcessExitIfBusy } from 'spiceflow' app.use(preventProcessExitIfBusy({ maxWaitSeconds: 60 }))
-
Type-safe
redirect()withSpiceflowRegister— when the app type is registered, the exportedredirect()helper validates route literals and requiresparamsfor parameterized paths likeredirect('/users/:id', { params: { id: '42' } }). Handler contextredirectstays broadly typed to avoid circular app type inference.
spiceflow@1.19.0-rsc.5
-
Automatic
waitUntilon Cloudflare Workers — Spiceflow now auto-detectswaitUntilfromcloudflare:workersvia a conditional package.json import map (#wait-until). No need to passwaitUntilin the constructor; background work scheduled viacontext.waitUntil()is forwarded to the Cloudflare execution context automatically. On Node.js and Bun, the default runs promises in the background with safe rejection handling so they don't crash the process. -
Resolved path type inference in
createSpiceflowFetch()— typed fetch calls now accept interpolated route strings like`/users/${id}`while preserving route-specific request and response inference. Previously only pattern-form paths like/users/:idwere type-safe. -
Shorter Server-Timing descriptions in Chrome DevTools — child spans no longer repeat the root request prefix on every row, making the waterfall easier to scan.