Modernized Mithril with Typescript, Bun tooling, SSR, Signals & State proxy
TypeScript
1
3,075 commits
updated Oct 7, 2026
Mithril.js with signals, reactive state, server rendering and a persistent store. Strict TypeScript, developed with Bun.
m.redraw(). state() makes
a plain object reactive, its functions become computeds. signal(), computed(), effect() and
watch() for direct use.@types package or build step. State, JSX attributes, routes
and m.route.Link are typed; the library has no any.oninit is awaited on the server; HTML and state go to the client, which hydrates
without refetching. Bun server helpers with sessions included.localStorage, sessionStorage, server session, or a cookie the
server can render from.Mithril v2 apps run unchanged, except m.request and streams: use fetch().
import m, {state} from '@bitstillery/mithril'
const $s = state({count: 0})
m.mount(document.body, {
view: () => <button onclick={() => $s.count++}>Clicked {$s.count} times</button>,
})
bun add @bitstillery/mithril
Guides: setup, signals,
state, SSR,
store; the rest of docs/site/content/ covers
core Mithril. Example apps: examples/state/, examples/ssr/.
bun install
bun test # tests
bun run lint # format, lint, type-check
bun run bench # benchmarks; bench:render etc. for one topic
MIT — see LICENSE. Mithril was created by Leo Horie; thanks to all Mithril.js contributors.
Modernized Mithril with Typescript, Bun tooling, SSR, Signals & State proxy
TypeScript
1
3,075 commits
updated Oct 7, 2026
Mithril.js with signals, reactive state, server rendering and a persistent store. Strict TypeScript, developed with Bun.
m.redraw(). state() makes
a plain object reactive, its functions become computeds. signal(), computed(), effect() and
watch() for direct use.@types package or build step. State, JSX attributes, routes
and m.route.Link are typed; the library has no any.oninit is awaited on the server; HTML and state go to the client, which hydrates
without refetching. Bun server helpers with sessions included.localStorage, sessionStorage, server session, or a cookie the
server can render from.Mithril v2 apps run unchanged, except m.request and streams: use fetch().
import m, {state} from '@bitstillery/mithril'
const $s = state({count: 0})
m.mount(document.body, {
view: () => <button onclick={() => $s.count++}>Clicked {$s.count} times</button>,
})
bun add @bitstillery/mithril
Guides: setup, signals,
state, SSR,
store; the rest of docs/site/content/ covers
core Mithril. Example apps: examples/state/, examples/ssr/.
bun install
bun test # tests
bun run lint # format, lint, type-check
bun run bench # benchmarks; bench:render etc. for one topic
MIT — see LICENSE. Mithril was created by Leo Horie; thanks to all Mithril.js contributors.