getAppliedNodeStack() — tailwindcss Function Reference
Architecture documentation for the getAppliedNodeStack() function in migrate-variant-order.ts from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD b676c746_a7f5_6343_837c_c251627d3cd1["getAppliedNodeStack()"] b3948c6e_ed8b_00c4_5c29_df98ab2469d3["isAtRuleVariant()"] b3948c6e_ed8b_00c4_5c29_df98ab2469d3 -->|calls| b676c746_a7f5_6343_837c_c251627d3cd1 91cd44e1_a9bd_4cc3_135a_48565792ef00["isCombinatorVariant()"] 91cd44e1_a9bd_4cc3_135a_48565792ef00 -->|calls| b676c746_a7f5_6343_837c_c251627d3cd1 ea9b4c5e_3f0c_08c2_79fe_f685bee1afab["isEndOfSelectorPseudoElement()"] ea9b4c5e_3f0c_08c2_79fe_f685bee1afab -->|calls| b676c746_a7f5_6343_837c_c251627d3cd1 e9d556bc_f22d_356c_1bd2_27442c34b5c7["walk()"] b676c746_a7f5_6343_837c_c251627d3cd1 -->|calls| e9d556bc_f22d_356c_1bd2_27442c34b5c7 style b676c746_a7f5_6343_837c_c251627d3cd1 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/@tailwindcss-upgrade/src/codemods/template/migrate-variant-order.ts lines 102–128
function getAppliedNodeStack(designSystem: DesignSystem, variant: Variant): AstNode[] {
let stack: AstNode[] = []
let ast = designSystem
.compileAstNodes({
kind: 'arbitrary',
property: 'color',
value: 'red',
modifier: null,
variants: [variant],
important: false,
raw: 'candidate',
})
.map((c) => c.node)
walk(ast, (node) => {
// Ignore the variant root class
if (node.kind === 'rule' && node.selector === '.candidate') {
return
}
// Ignore the dummy declaration
if (node.kind === 'declaration' && node.property === 'color' && node.value === 'red') {
return
}
stack.push(node)
})
return stack
}
Domain
Subdomains
Calls
Source
Frequently Asked Questions
What does getAppliedNodeStack() do?
getAppliedNodeStack() is a function in the tailwindcss codebase.
What does getAppliedNodeStack() call?
getAppliedNodeStack() calls 1 function(s): walk.
What calls getAppliedNodeStack()?
getAppliedNodeStack() is called by 3 function(s): isAtRuleVariant, isCombinatorVariant, isEndOfSelectorPseudoElement.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free