migrate() — tailwindcss Function Reference
Architecture documentation for the migrate() function in migrate-theme-to-var.test.ts from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD 52eccd67_a1a1_1568_397e_4f4e39b2a252["migrate()"] f0ca3f14_54b1_e7ee_5976_811ab796b63a["migrateThemeToVar()"] 52eccd67_a1a1_1568_397e_4f4e39b2a252 -->|calls| f0ca3f14_54b1_e7ee_5976_811ab796b63a e043f45b_85cc_a577_dfe0_8d4c73200c27["sortBuckets()"] 52eccd67_a1a1_1568_397e_4f4e39b2a252 -->|calls| e043f45b_85cc_a577_dfe0_8d4c73200c27 a342f353_2ecc_4db5_ac10_390f5d309eea["formatNodes()"] 52eccd67_a1a1_1568_397e_4f4e39b2a252 -->|calls| a342f353_2ecc_4db5_ac10_390f5d309eea style 52eccd67_a1a1_1568_397e_4f4e39b2a252 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/@tailwindcss-upgrade/src/codemods/css/migrate-theme-to-var.test.ts lines 11–24
async function migrate(input: string) {
return postcss()
.use(
migrateThemeToVar({
designSystem: await __unstable__loadDesignSystem(`@import 'tailwindcss';`, {
base: __dirname,
}),
}),
)
.use(sortBuckets())
.use(formatNodes())
.process(input, { from: expect.getState().testPath })
.then((result) => result.css)
}
Domain
Subdomains
Source
Frequently Asked Questions
What does migrate() do?
migrate() is a function in the tailwindcss codebase.
What does migrate() call?
migrate() calls 3 function(s): formatNodes, migrateThemeToVar, sortBuckets.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free