Home / Function/ scan() — tailwindcss Function Reference

scan() — tailwindcss Function Reference

Architecture documentation for the scan() function in mod.rs from the tailwindcss codebase.

Entity Profile

Dependency Diagram

graph TD
  89b17e28_39e8_3896_8c5e_c9b6a2860e73["scan()"]
  0893876a_99f6_89ff_2ab7_5dcebb0e7e13["scan_sources()"]
  89b17e28_39e8_3896_8c5e_c9b6a2860e73 -->|calls| 0893876a_99f6_89ff_2ab7_5dcebb0e7e13
  c89b240d_593b_77f4_98be_01fdb9aae54a["extract_candidates()"]
  89b17e28_39e8_3896_8c5e_c9b6a2860e73 -->|calls| c89b240d_593b_77f4_98be_01fdb9aae54a
  a24547bd_a4d8_c969_9693_3649cf9918a1["iter()"]
  89b17e28_39e8_3896_8c5e_c9b6a2860e73 -->|calls| a24547bd_a4d8_c969_9693_3649cf9918a1
  style 89b17e28_39e8_3896_8c5e_c9b6a2860e73 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

crates/oxide/src/scanner/mod.rs lines 181–197

    pub fn scan(&mut self) -> Vec<String> {
        self.scan_sources();

        // TODO: performance improvement, bail early if we don't have any changed content
        // if self.changed_content.is_empty() {
        //     return vec![];
        // }

        let _new_candidates = self.extract_candidates();

        // Make sure we have a sorted list of candidates
        let mut candidates = self.candidates.iter().cloned().collect::<Vec<_>>();
        candidates.par_sort_unstable();

        // Return all candidates instead of only the new ones
        candidates
    }

Domain

Subdomains

Frequently Asked Questions

What does scan() do?
scan() is a function in the tailwindcss codebase.
What does scan() call?
scan() calls 3 function(s): extract_candidates, iter, scan_sources.

Analyze Your Own Codebase

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

Try Supermodel Free