candidateValue() — tailwindcss Function Reference
Architecture documentation for the candidateValue() function in theme.ts from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD 34006e43_988b_b22f_7808_6d387d527db3["candidateValue()"] 678fff87_ea5f_81ce_f4c8_aba1e92f475b["isIgnoredThemeKey()"] 34006e43_988b_b22f_7808_6d387d527db3 -->|calls| 678fff87_ea5f_81ce_f4c8_aba1e92f475b style 34006e43_988b_b22f_7808_6d387d527db3 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/tailwindcss/src/theme.ts lines 168–191
#resolveKey(candidateValue: string | null, themeKeys: ThemeKey[]): string | null {
for (let namespace of themeKeys) {
let themeKey =
candidateValue !== null ? (`${namespace}-${candidateValue}` as ThemeKey) : namespace
if (!this.values.has(themeKey)) {
// If the exact theme key is not found, we might be trying to resolve a key containing a dot
// that was registered with an underscore instead:
if (candidateValue !== null && candidateValue.includes('.')) {
themeKey = `${namespace}-${candidateValue.replaceAll('.', '_')}` as ThemeKey
if (!this.values.has(themeKey)) continue
} else {
continue
}
}
if (isIgnoredThemeKey(themeKey, namespace)) continue
return themeKey
}
return null
}
Domain
Subdomains
Calls
Source
Frequently Asked Questions
What does candidateValue() do?
candidateValue() is a function in the tailwindcss codebase.
What does candidateValue() call?
candidateValue() calls 1 function(s): isIgnoredThemeKey.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free