test_maud_template_extraction() — tailwindcss Function Reference
Architecture documentation for the test_maud_template_extraction() function in rust.rs from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD 8608d127_e74b_1a75_afeb_091eb8451656["test_maud_template_extraction()"] e4f33efa_e6ad_42c6_e565_e6aa98401427["rust.rs"] 8608d127_e74b_1a75_afeb_091eb8451656 -->|defined in| e4f33efa_e6ad_42c6_e565_e6aa98401427 style 8608d127_e74b_1a75_afeb_091eb8451656 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
crates/oxide/src/extractor/pre_processors/rust.rs lines 154–215
fn test_maud_template_extraction() {
let input = r#"
use maud::{html, Markup};
pub fn main() -> Markup {
html! {
header.px-8.py-4.text-black {
"Hello, world!"
}
}
}
"#;
Rust::test_extract_contains(input, vec!["px-8", "py-4", "text-black"]);
// https://maud.lambda.xyz/elements-attributes.html#classes-and-ids-foo-bar
let input = r#"
html! {
input #cannon .big.scary.bright-red type="button" value="Launch Party Cannon";
}
"#;
Rust::test_extract_contains(input, vec!["big", "scary", "bright-red"]);
let input = r#"
html! {
div."bg-[#0088cc]" { "Quotes for backticks" }
}
"#;
Rust::test_extract_contains(input, vec!["bg-[#0088cc]"]);
let input = r#"
html! {
#main {
"Main content!"
.tip { "Storing food in a refrigerator can make it 20% cooler." }
}
}
"#;
Rust::test_extract_contains(input, vec!["tip"]);
let input = r#"
html! {
div."bg-[url(https://example.com)]" { "Arbitrary values" }
}
"#;
Rust::test_extract_contains(input, vec!["bg-[url(https://example.com)]"]);
let input = r#"
html! {
div.px-4.text-black {
"Some text, with unbalanced brackets ]["
}
div.px-8.text-white {
"Some more text, with unbalanced brackets ]["
}
}
"#;
Rust::test_extract_contains(input, vec!["px-4", "text-black", "px-8", "text-white"]);
let input = r#"html! { \x.px-4.text-black { } }"#;
Rust::test(input, r#"html! { \x px-4 text-black { } }"#);
}
Domain
Subdomains
Source
Frequently Asked Questions
What does test_maud_template_extraction() do?
test_maud_template_extraction() is a function in the tailwindcss codebase, defined in crates/oxide/src/extractor/pre_processors/rust.rs.
Where is test_maud_template_extraction() defined?
test_maud_template_extraction() is defined in crates/oxide/src/extractor/pre_processors/rust.rs at line 154.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free