A Prettier plugin that formats Rust code, autocorrects syntax errors, and works with incomplete code.
Prettier Rust is a Prettier plugin that formats Rust code. It provides error-tolerant formatting that works even with incomplete or syntactically incorrect code, and it automatically fixes common syntax errors like missing semicolons and parentheses.
Rust developers who use Prettier for other languages and want a consistent, editor-integrated formatting experience, especially those working in VS Code or other editors with Prettier support.
Developers choose Prettier Rust over alternatives like rustfmt for its ability to format code that won't compile, its strong editor integration with autocorrection, and its uniform, opinionated style with no configuration options.
Prettier Rust is an opinionated code formatter that autocorrects bad syntax.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Formats Rust code even with syntax errors or missing annotations, as shown in the README's example table, which fixes seven errors in incomplete code.
Automatically fixes common errors like missing semicolons and parentheses, acting like auto-applying Rust compiler suggestions to speed up development.
Offers a dedicated VS Code extension for easy installation and auto-updates, providing a seamless formatting experience directly in the editor.
Enforces a consistent, opinionated style with no configuration options, based on Prettier's battle-tested approach from TypeScript, reducing style debates.
The README admits that key Prettier options like 'trailingComma' and 'embeddedLanguageFormatting' are not yet supported, limiting customization for some use cases.
Requires Node.js and isn't as tightly integrated with Rust's native tooling like cargo, making it less convenient for projects that prefer Rust-only workflows.
Relies on jinx-rust instead of the official rustc parser, which may introduce stability risks or lag in supporting new Rust features compared to rustfmt.