A Rust procedural macro that removes leading indentation from string literals.
Find a file
2025-11-20 09:27:38 -08:00
src Implement dedent proc_macro 2025-11-20 01:27:59 -08:00
tests Implement dedent proc_macro 2025-11-20 01:27:59 -08:00
.gitignore Add lockfile and ignore target 2025-11-20 09:27:38 -08:00
Cargo.lock Add lockfile and ignore target 2025-11-20 09:27:38 -08:00
Cargo.toml Implement dedent proc_macro 2025-11-20 01:27:59 -08:00
readme.md Implement dedent proc_macro 2025-11-20 01:27:59 -08:00

dedent

A procedural macro that removes leading indentation from string literals.

[dependencies]
dedent = { version = "0.1", registry = "nettika" }

Example

use dedent::dedent;

let xml = dedent! {r#"
    <root>
        <item id="3"/>
    </root>
"#};

assert_eq!(xml, r#"<root>
    <item id="3"/>
</root>"#);