deprecatedUtilities() — tailwindcss Function Reference
Architecture documentation for the deprecatedUtilities() function in canonicalize-candidates.ts from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD 7be21eb0_b210_7689_9091_6c6381320e8b["deprecatedUtilities()"] f6c14bbb_2e42_58cc_18f1_c89a243da9c0["canonicalize-candidates.ts"] 7be21eb0_b210_7689_9091_6c6381320e8b -->|defined in| f6c14bbb_2e42_58cc_18f1_c89a243da9c0 b12efe90_482b_52b8_1913_f2eb419a12f7["printUnprefixedCandidate()"] 7be21eb0_b210_7689_9091_6c6381320e8b -->|calls| b12efe90_482b_52b8_1913_f2eb419a12f7 bafed062_abf8_7e47_4942_385b21bd9b04["parseCandidate()"] 7be21eb0_b210_7689_9091_6c6381320e8b -->|calls| bafed062_abf8_7e47_4942_385b21bd9b04 2820372c_b982_9e06_fc23_f8f4ac308d00["get()"] 7be21eb0_b210_7689_9091_6c6381320e8b -->|calls| 2820372c_b982_9e06_fc23_f8f4ac308d00 style 7be21eb0_b210_7689_9091_6c6381320e8b fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/tailwindcss/src/canonicalize-candidates.ts lines 1282–1305
function deprecatedUtilities(
candidate: Candidate,
options: InternalCanonicalizeOptions,
): Candidate {
let designSystem = options.designSystem
let signatures = designSystem.storage[UTILITY_SIGNATURE_KEY].get(options.signatureOptions)
let targetCandidateString = printUnprefixedCandidate(designSystem, candidate)
let replacementString = DEPRECATION_MAP.get(targetCandidateString) ?? null
if (replacementString === null) return candidate
let legacySignature = signatures.get(targetCandidateString)
if (typeof legacySignature !== 'string') return candidate
let replacementSignature = signatures.get(replacementString)
if (typeof replacementSignature !== 'string') return candidate
// Not the same signature, not safe to migrate
if (legacySignature !== replacementSignature) return candidate
let [replacement] = parseCandidate(designSystem, replacementString)
return replacement
}
Domain
Subdomains
Source
Frequently Asked Questions
What does deprecatedUtilities() do?
deprecatedUtilities() is a function in the tailwindcss codebase, defined in packages/tailwindcss/src/canonicalize-candidates.ts.
Where is deprecatedUtilities() defined?
deprecatedUtilities() is defined in packages/tailwindcss/src/canonicalize-candidates.ts at line 1282.
What does deprecatedUtilities() call?
deprecatedUtilities() calls 3 function(s): get, parseCandidate, printUnprefixedCandidate.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free