Home / Function/ test_strict_locals() — tailwindcss Function Reference

test_strict_locals() — tailwindcss Function Reference

Architecture documentation for the test_strict_locals() function in ruby.rs from the tailwindcss codebase.

Entity Profile

Dependency Diagram

graph TD
  7e99492e_ef09_d247_3d3c_0f4b25481cdc["test_strict_locals()"]
  de63b342_bc8b_68a8_063b_cc3f8524fd2c["ruby.rs"]
  7e99492e_ef09_d247_3d3c_0f4b25481cdc -->|defined in| de63b342_bc8b_68a8_063b_cc3f8524fd2c
  style 7e99492e_ef09_d247_3d3c_0f4b25481cdc fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

crates/oxide/src/extractor/pre_processors/ruby.rs lines 405–429

    fn test_strict_locals() {
        // Strict locals are defined in a `<%# locals: … %>`, but the `#` looks like a comment
        // which we should not ignore in this case.
        let input = r#"
          <%# locals: (css: "text-amber-600") %>
          <% more_css = "text-sky-500" %>

          <p class="text-green-500">
            In a partial
          </p>

          <p class="<%= css %>">
            In a partial using explicit local variables
          </p>

          <p class="<%= more_css %>">
            In a partial using explicit local variables
          </p>
        "#;

        Ruby::test_extract_contains(
            input,
            vec!["text-amber-600", "text-sky-500", "text-green-500"],
        );
    }

Domain

Subdomains

Frequently Asked Questions

What does test_strict_locals() do?
test_strict_locals() is a function in the tailwindcss codebase, defined in crates/oxide/src/extractor/pre_processors/ruby.rs.
Where is test_strict_locals() defined?
test_strict_locals() is defined in crates/oxide/src/extractor/pre_processors/ruby.rs at line 405.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free