Skip to content

v1.8.0

Choose a tag to compare

@cpojer cpojer released this 12 Nov 01:18
· 42 commits to main since this release
Immutable release. Only release title and notes can be modified.
  • Added _not-found and _error Pages components to show errors inside your layouts, with support for nested boundaries across all four framework adapters.
  • Added throwOnError: false to useForm() to keep authentication and server errors inline without losing form input.
  • Added a session option to createDb() for D1 reads that need to start on the primary.
  • Added per-project AI Gateway logging controls, including metadata-only logging that omits prompt and response bodies.
  • Added ActionResult and getValidationErrors() exports to all framework adapters.
  • Added Drizzle’s SQL, SQLWrapper, AnyColumn, and BatchItem type exports to void/db.
  • Added query parameter support to typed named action URLs.
  • Upgraded to Vite+ 1.6, including newly created projects, and updated Cloudflare tooling.
  • Fixed actions dropping the current page’s query parameters and changing the URL, scroll position, or history when updating the page in place.
  • Fixed Vue, Svelte, and Solid forms losing edits made during submission and older submissions overwriting newer form state.
  • Fixed React navigation losing its destination and method while a transition is pending.
  • Fixed D1 authentication reads seeing stale data from replicas.
  • Fixed defaults and automatic updatedAt values when writing to generated Better Auth tables through Drizzle.
  • Fixed async env.ts validators failing in app requests and background jobs.
  • Fixed Vue pages with inline typed props failing to receive their props correctly.
  • Fixed app tests failing because Void tried to start a Worker or run migrations under Vitest.
  • Fixed intentional Worker 404 responses being replaced by static assets on native Cloudflare deployments.
  • Fixed Cloudflare preview and deployment failures for static apps with overlapping server route patterns.
  • Fixed a race between void secret put and the first Cloudflare deployment.
  • Improved diagnostics for queue options and Pages settings that cannot be inferred.
  • Fixed new projects’ .gitignore encouraging .env.example files that Void does not support.
  • Added a testing guide and an llms.txt index for the documentation.

Thanks to @dvkam, @jong-kyung, @karthickeyan-dev, @morinokami, @ubugeeei, and @yangshun for their contributions!

Not Found & Error Pages

Add _not-found and _error components to pages/ or a subdirectory to show errors inside your layouts. Both receive an error prop with status and message. A loader can show the nearest not-found component with c.notFound():

import { defineHandler } from 'void';

export const loader = defineHandler((c) => c.notFound());

Not found and errors

Inline Form Errors

Keep authentication and server errors in form.error, with the form and its input still visible:

import { useForm } from '@void/react'; // or "@void/vue", "@void/svelte", "@void/solid"

const form = useForm(
  '/users',
  { name: '', email: '' },
  { throwOnError: false },
);

Handling action errors

Fresh D1 Reads

Use session: 'first-primary' when a request needs the latest primary data while keeping Drizzle’s schema and query types:

import { users } from '@schema';
import { env } from 'cloudflare:workers';
import { defineHandler } from 'void';
import { createDb } from 'void/db';

export const GET = defineHandler(async () => {
  const db = createDb(env.DB, { session: 'first-primary' });
  return db.select().from(users).all();
});

D1 read replication

Per-Project AI Logging

Platform administrators can keep prompt and response bodies out of a project’s AI Gateway logs while retaining request metadata:

void platform project ai-logging <project-id> metadata

AI Gateway logging