# threadloom
[](https://crates.io/crates/threadloom)
[](https://docs.rs/threadloom)
[](../../LICENSE)
> Full-stack Rust β one language, one codebase, WASM frontend + native backend.
Threadloom is a Rust framework for building full-stack web apps. Write your UI in Rust using a JSX-like macro, compile to WASM for the browser, and deploy your API as a native binary β to a server or Vercel.
---
## Quick Start
```bash
# Install the CLI
cargo install distaff
# Scaffold a new project
distaff new my-app
cd my-app
# Start dev server with hot reload
distaff dev
```
---
## Features
- β‘ **Rust everywhere** β no JS/TS in your codebase
- πΈοΈ **WASM-first frontend** β compile your UI to WebAssembly
- π οΈ **`distaff` CLI** β hot reload, dev server, production builds
- π **One-command Vercel deployment** β `distaff build --vercel`
- π **Reactive state with signals** β fine-grained reactivity
---
## Example
```rust
use threadloom::prelude::*;
#[component]
fn Counter() -> View {
let count = signal(0);
let increment = move |_| count.set(count.get() + 1);
view! {
<div class="counter">
<h1>{ count }</h1>
<button onclick={increment}>"Click me"</button>
</div>
}
}
```
---
## Crate Structure
| `threadloom` | Main re-export crate (start here) |
| `threadloom-core` | Shared types, signal primitives, HTTP client |
| `threadloom-dom` | WASM DOM diffing and rendering engine |
| `threadloom-macro` | `view!` proc macro for JSX-like templates |
| `threadloom-ui` | Built-in UI components |
| `threadloom-scheduler` | Async task scheduler |
| `threadloom-server` | Server abstraction (Actix + Vercel runtime) |
| `threadloom-desktop` | Desktop app wrapper (coming soon) |
| `distaff` | CLI tool: new, dev, build, hot-reload |
---
## License
[MIT](../../LICENSE)