extractRawCandidates() — tailwindcss Function Reference
Architecture documentation for the extractRawCandidates() function in candidates.ts from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD 32321edd_136f_72af_2493_29416c9351fa["extractRawCandidates()"] 079e0035_1ce3_3d9d_3017_71b47a7375a1["migrateContents()"] 079e0035_1ce3_3d9d_3017_71b47a7375a1 -->|calls| 32321edd_136f_72af_2493_29416c9351fa style 32321edd_136f_72af_2493_29416c9351fa fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/@tailwindcss-upgrade/src/codemods/template/candidates.ts lines 5–17
export async function extractRawCandidates(
content: string,
extension: string = 'html',
): Promise<{ rawCandidate: string; start: number; end: number }[]> {
let scanner = new Scanner({})
let result = scanner.getCandidatesWithPositions({ content, extension })
let candidates: { rawCandidate: string; start: number; end: number }[] = []
for (let { candidate: rawCandidate, position: start } of result) {
candidates.push({ rawCandidate, start, end: start + rawCandidate.length })
}
return candidates
}
Domain
Subdomains
Called By
Source
Frequently Asked Questions
What does extractRawCandidates() do?
extractRawCandidates() is a function in the tailwindcss codebase.
What calls extractRawCandidates()?
extractRawCandidates() is called by 1 function(s): migrateContents.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free