dioxus/packages/autofmt
Evan Almloff 2523581cf4
Autocomplete rsx (#2421)
* autocomplete rsx

* hide the completions module

* fix autocomplete for identifiers that start with a raw identifier

* add field completion hints for props

* remove extra import

* Revert "add field completion hints for props"

This reverts commit 194899c737.

* fix autocomplete inside raw expressions

* fix autofmt

* feat: just use regular ifmt if it's compatible

reuses the tokens for ifmt so RA provides its HIR lowering on simple formatted strings

* fix merging ifmt strings

* add a better error message for components called like functions

---------

Co-authored-by: Jonathan Kelley <jkelleyrtp@gmail.com>
2024-05-22 07:24:50 -05:00
..
.vscode Fixes to autofmt, make it more aggressive (#2230) 2024-04-03 15:27:36 -07:00
src Autocomplete rsx (#2421) 2024-05-22 07:24:50 -05:00
tests Fix: flaky CI by correcting autofmt to match proper spacing (#2369) 2024-04-26 12:04:56 -04:00
Cargo.toml Autofmt nested rsx using syn::Visitor (#2279) 2024-04-08 22:15:52 -07:00
README.md Fix Outdated README.md (#2147) 2024-03-26 19:17:02 -07:00

dioxus-autofmt

Crates.io MIT licensed Build Status Discord chat

Website | Guides | API Docs | Chat

Overview

dioxus-autofmt provides a pretty printer for the rsx syntax tree.

This is done manually with a via set of formatting rules. The output is not guaranteed to be stable between minor versions of the crate as we might tweak the output.

dioxus-autofmt provides an API to perform precision edits as well as just spit out a block of formatted RSX from any RSX syntax tree. This is used by the rsx-rosetta crate which can accept various input languages and output valid RSX.

Contributing

  • Report issues on our issue tracker.
  • Join the discord and ask questions!

License

This project is licensed under the MIT license.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Dioxus by you shall be licensed as MIT without any additional terms or conditions.