extractRawCandidates() — tailwindcss Function Reference
Architecture documentation for the extractRawCandidates() function in candidates.ts from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD f2c36345_eddf_1720_9a42_e1a49f2c7132["extractRawCandidates()"] 6818f003_fa74_ca6e_8dd1_99a7154be5c9["candidates.ts"] f2c36345_eddf_1720_9a42_e1a49f2c7132 -->|defined in| 6818f003_fa74_ca6e_8dd1_99a7154be5c9 404037a5_0bed_880c_5e9a_954d7ffbf6d7["migrateContents()"] 404037a5_0bed_880c_5e9a_954d7ffbf6d7 -->|calls| f2c36345_eddf_1720_9a42_e1a49f2c7132 style f2c36345_eddf_1720_9a42_e1a49f2c7132 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, defined in packages/@tailwindcss-upgrade/src/codemods/template/candidates.ts.
Where is extractRawCandidates() defined?
extractRawCandidates() is defined in packages/@tailwindcss-upgrade/src/codemods/template/candidates.ts at line 5.
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