One source of truth.
Declare a table, authorize its rows, and write a query. Hearth uses that query for the initial render and the browser's live results.
#[derive(Table)]
live_query! { ... }A local-first web framework. Render on the server. Query in the browser. Write your app in one language.
Real queries. Real writes. No app JavaScript.
// Query excerpt. Server and browser.
let issues = live_query! {
DemoItem from i in IssueRow
where if $(!search.get().is_empty()) {
i.title contains $(search.get())
}
order by i.position
select {
id: i.id,
title: i.title,
open: i.open
}
};// Query excerpt. Server and browser.
let issues = live_query! {
DemoItem from i in IssueRow
where if $(!search.get().is_empty()) {
i.title contains $(search.get())
}
order by i.position
select {
id: i.id,
title: i.title,
open: i.open
}
};view! {
<ul>
for issue in $(issues) {
<li>
<button @click=$(|_e| {
table.set(
issue.id.clone(),
"open", !issue.open
)
})>
$(issue.title.clone())
</button>
</li>
}
</ul>
}No matches. Try a different filter.
Illustrative data, isolated to this browser. Filter locally; toggle a row to make an optimistic write, validated by the Rust server.
Declare a table, authorize its rows, and write a query. Hearth uses that query for the initial render and the browser's live results.
#[derive(Table)]
live_query! { ... }The server sends rendered content. Client expressions compile to small JavaScript modules. No client-side Rust or WebAssembly download.
Rust → HTML + JavaScriptIndexed queries run against local tables. Writes update the interface immediately, then the server validates them. Rejected writes roll back.
local query → update → syncNot another data layer to wire into your stack. A framework for the page, the data, and the space between.
Hearth is early, opinionated, and ready to be explored. Start with a small app. Tell us where it gets in your way.
Build your first pageStart with crates.io
rustup toolchain install 1.99.1
cargo new my-hearth-app
cd my-hearth-app
rustup override set 1.99.1
cargo add hearth@=0.1.0
cargo add tokio --features rt-multi-thread,macros
cargo install hearth-cli --version 0.1.0 --lockedHearth 0.1.0 is published. Use Rust 1.99.1, then follow the guide for a complete first page. No Node.js or pnpm required for your app.
See setup and running instructions →Hearth is experimental. APIs will change. Browser persistence caches server rows; it is not a durable offline write queue. The current sync path scans scoped tables, so test it with your own data and permissions.
Read the current boundaries →