How v3dant21/grpc-todo works
Project type and purpose
• This is a Rust-based full-stack To-Do web application.
• Frontend: HTMX + Warp (serves HTML & handles HTMX requests).
• Backend: gRPC API (CRUD operations on todos).
• Persistence: SQLite with SQL migrations.
• Orchestration: Cargo workspaces + Cargo-Make to build/run both services.
File structure
• Workspace root
• Cargo.toml (defines both workspace members)
• makefile.toml (Cargo-Make tasks: run frontend, backend, migrations)
• grpc-todo (gRPC backend service)
• proto/todo.proto → gRPC service & message definitions
• build.rs → generates Rust code from .proto
• src/main.rs → CLI entry point (e.g. migrate, server)
• src/server.rs → sets up the gRPC server
• src/db.rs, migrations/*.sql → database setup & query layer
• htmx-warp (Frontend + HTTP→gRPC client)
• proto/todo.proto → shared definitions (client stubs)
• build.rs → generates client code
• src/index.html → HTMX-powered UI
• src/main.rs → Warp routes that serve index.html and proxy HTMX calls to gRPC backend
• SQLite files (todo.db, -shm, -wal) in workspace root
README for additional insights
• Tech stack: gRPC, HTMX, Warp, SQLite, Cargo workspaces/make
• Features: real-time UI via HTMX, modular crates, one-command run
• Setup: run migrations then “cargo make run-both” to start both services