codeitlikemiley/leptos-fmt — explained in plain English
Analysis updated 2026-07-19 · repo last pushed 2025-03-12
Automatically format Leptos view code every time you save a Rust file in VS Code.
Manually trigger formatting with a keyboard shortcut in multi-project workspaces to keep settings isolated.
Point the extension to a custom leptosfmt binary or Cargo home when your Rust toolchain is in a non-standard location.
Run the Leptos Init command to auto-generate formatter configuration without editing settings files by hand.
| codeitlikemiley/leptos-fmt | 0labs-in/vision-link | arviahq/arvia | |
|---|---|---|---|
| Stars | 4 | 4 | 4 |
| Language | TypeScript | TypeScript | TypeScript |
| Last pushed | 2025-03-12 | — | — |
| Maintenance | Stale | — | — |
| Setup difficulty | moderate | moderate | moderate |
| Complexity | 2/5 | 3/5 | 3/5 |
| Audience | developer | developer | developer |
Figures from each repo's GitHub metadata at analysis time.
Requires the external leptosfmt CLI tool installed separately via Cargo, plus Rust Analyzer running in VS Code.
Leptos-fmt is a VS Code extension that automatically formats code written with Leptos, a popular Rust framework for building web apps. If you've ever used a code formatter that cleans up indentation and spacing on save, this does exactly that, but specifically for Rust files containing Leptos components. Without it, standard Rust formatters can stumble over Leptos's inline HTML-like syntax, leaving your code messy or incorrectly structured. Once installed, the extension taps into Rust Analyzer (the language server that powers Rust development in VS Code) and tells it to use a separate tool called leptosfmt for formatting instead of the default Rust formatter. You run a command called "Leptos Init" from VS Code's command palette, and the extension writes the necessary configuration into your project's settings file. After that, formatting just works as part of your normal workflow. For more complex setups, say you have multiple projects in one workspace and don't want formatting settings from one leaking into another, the extension offers a "Format with Leptosfmt" command you can trigger manually or bind to a keyboard shortcut. You can also point the extension to custom paths for the leptosfmt binary and your Cargo home directory, which is useful if your Rust toolchain lives in a non-standard location. This tool is built for developers already working with Leptos in VS Code. A typical user might be someone building a full-stack Rust web app who wants their Leptos views to stay consistently formatted without fighting the default Rust formatter. The extension is lightweight, it's essentially a bridge between VS Code, Rust Analyzer, and the leptosfmt command-line tool, which you need to install separately via Rust's package manager. That means it relies on that external tool being present, but it spares you from having to manually wire all the configuration together yourself.
A VS Code extension that automatically formats Rust code using the Leptos web framework, bridging VS Code's Rust Analyzer with the leptosfmt command-line tool so inline HTML-like view syntax stays clean on save.
Mainly TypeScript. The stack also includes TypeScript, VS Code Extension API, Rust Analyzer.
Stale — no commits in 1-2 years (last push 2025-03-12).
No license information is provided in the repository, so usage terms are unclear.
Setup difficulty is rated moderate, with roughly 5min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
double-check against the repo, no cap.