Arachne builds static sites, server‑rendered apps and APIs from one TypeScript codebase, on Bun.
bunx @arachnejs/kit create my-app --template static
cd my-app && bun install
bun run dev
Version 0.1.1 is a pre-release: APIs can still change. Getting started walks through a first app.
Pages are JSX compiled to direct DOM operations. State lives in signals, so a change updates the text node or attribute that reads it: components run once, and there is no virtual DOM to diff. The route table, with its layouts, data loaders and head tags, runs on the server, at build time and in the browser.
On the server, one schema validates a request, types the handler, and produces the OpenAPI document and the typed client. Accounts, sessions, permissions, mail, file storage and migrations ship as packages of the framework, each usable on its own.
A page with loader data, and a validated API route. Requests without a name get a 422 before the handler runs.
import type { RouteDefinition, RouteProps } from "@arachnejs/router";
import { signal } from "@arachnejs/signals";
function Home(props: RouteProps) {
const data = props.data as { now: string };
const count = signal(0);
return (
<main>
<h1>Hello, Arachne</h1>
<p>Rendered at {data.now}.</p>
<button type="button" onClick={() => count.set(count() + 1)}>
Clicked {count()} times
</button>
</main>
);
}
export const routes: RouteDefinition[] = [
{ path: "/", component: Home, head: { title: "Home" } },
];import { defineServer } from "@arachnejs/kit";
import { s } from "@arachnejs/schema";
import { route } from "@arachnejs/server";
const greet = route({
method: "GET",
path: "/api/greet",
query: s.object({ name: s.string({ min: 1, max: 40 }) }),
handler: (ctx) => ({ message: `Hello, ${ctx.query.name}!` }),
});
export default defineServer({
routes: [greet],
loaders: {
"/": () => ({ now: new Date().toISOString() }),
},
});Pages
- @arachnejs/kitArachne app kit: static, server and API apps, SSR, prerendering, dev server with hot reload, CLI
- @arachnejs/routerSignal-driven client router for Arachne
- @arachnejs/renderSSR/DOM render runtime and islands for Arachne
- @arachnejs/signalsFine-grained signals for Arachne (alien-signals facade)
- @arachnejs/jsxJSX compiler for Arachne (dom-expressions / oxc)
- @arachnejs/viteBun and Vite plugins for @arachnejs/jsx
Server and data
- @arachnejs/serverHTTP server for Arachne: typed validated routes, uploads, OpenAPI, middleware
- @arachnejs/schemaStandard Schema DSL for Arachne (one schema, many outputs)
- @arachnejs/dbSchema-aware database client for Arachne
- @arachnejs/db-sqliteSQLite dialect for @arachnejs/db (bun:sqlite)
- @arachnejs/migrateVersioned database migrations and schema diffing for @arachnejs/db
- @arachnejs/authAccounts, sessions, API tokens, 2FA, blocking and access control for Arachne
- @arachnejs/aclAccess control for Arachne: permissions, groups, levels, conditions
- @arachnejs/mailerEmail for Arachne: typed templates, SMTP/HTTP/memory/file transports
- @arachnejs/storageFile storage for Arachne: memory, local disk and S3 drivers
UI
- @arachnejs/uiUI primitives for Arachne (JSX + signals)
- @arachnejs/formsSchema-bound forms for Arachne
Foundation
- @arachnejs/coreArachne kernel: DI container, modules, events, logger
- @arachnejs/configTyped config loader for Arachne (file + env + CLI)
- @arachnejs/mcpMCP kernel for Arachne — compose per-package tool modules
- @arachnejs/testingTest utilities for Arachne packages
On by default:
- CSP with a per-request nonce, HSTS, nosniff, frame and referrer policies
- Every declared input validated; failures answer 422 with the path of each issue
- Parameterised SQL only; update and delete refuse to run without a where clause
- argon2id passwords, hashed session and API tokens, __Host- cookies
- CSRF checks via Origin and Fetch Metadata, login lockout, rate limits, audit events
Pre-release. Static, server and API apps work end to end and are covered by unit, process and browser tests. Not done yet: Postgres and MySQL drivers, OAuth and passkeys, streaming SSR, a GraphQL adapter. The progress log has the details.
Read nextGetting startedFramework guidekitrouterserverschemaauthui
arachne 0.1.12026-09-30 · d1aad1b68 pages