onlyAllowedThemeValues() — tailwindcss Function Reference
Architecture documentation for the onlyAllowedThemeValues() function in migrate-js-config.ts from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD de5db066_e1d3_0f2c_384e_f5811833f5ee["onlyAllowedThemeValues()"] 392cc8ca_1b35_56b9_6e03_2bbdf381e0f2["canMigrateConfig()"] 392cc8ca_1b35_56b9_6e03_2bbdf381e0f2 -->|calls| de5db066_e1d3_0f2c_384e_f5811833f5ee style de5db066_e1d3_0f2c_384e_f5811833f5ee fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/@tailwindcss-upgrade/src/codemods/config/migrate-js-config.ts lines 474–489
function onlyAllowedThemeValues(theme: ThemeConfig): boolean {
for (let key of Object.keys(theme)) {
if (!ALLOWED_THEME_KEYS.includes(key)) {
return false
}
}
if ('screens' in theme && typeof theme.screens === 'object' && theme.screens !== null) {
for (let screen of Object.values(theme.screens)) {
if (typeof screen === 'object' && screen !== null && ('max' in screen || 'raw' in screen)) {
return false
}
}
}
return true
}
Domain
Subdomains
Called By
Source
Frequently Asked Questions
What does onlyAllowedThemeValues() do?
onlyAllowedThemeValues() is a function in the tailwindcss codebase.
What calls onlyAllowedThemeValues()?
onlyAllowedThemeValues() is called by 1 function(s): canMigrateConfig.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free