chore: migrate from Tailwind CSS v3 to v4#287
Merged
andygrunwald merged 1 commit intomainfrom Mar 22, 2026
Merged
Conversation
- Replace @astrojs/tailwind (deprecated) with @tailwindcss/vite plugin - Convert tailwind.config.cjs to CSS-first @theme config in global.css - Convert newspost.scss to plain CSS (SCSS not supported in v4) - Remove sass dependency (no longer needed) - Replace bg-body with bg-white in layouts (v4 single color per name) - Add @reference directive for @apply in component CSS files - Update CI workflow paths (remove deleted tailwind.config.cjs) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
✅ Deploy Preview for lively-frangollo-e43a02 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
@astrojs/tailwindintegration with@tailwindcss/viteplugintailwind.config.cjs(554 lines) to a@themeblock insrc/styles/global.cssnewspost.scssto plain CSS (SCSS not supported in Tailwind v4)sassdependencyKey changes
@astrojs/tailwind,sass; added@tailwindcss/vite; updatedtailwindcssto v4integrations: [tailwind()]tovite: { plugins: [tailwindcss()] }@themedirective. Standard color palettes (gray, red, yellow, etc.) are identical to v4 defaults and omitted.bg-body/text-bodysplit: In v3 these mapped to different colors (#fff / #1e293b). In v4 a single--color-bodygenerates both. Solved by usingbg-whitefor backgrounds and--color-body: #1e293bfor text.@layer baserule to preserve v3's#e2e8f0default (v4 defaults tocurrentColor)@apply(no SCSS-specific features), so the conversion is a file rename +@referencedirective for v4 compatibilitytailwind.config.cjsfrom workflow path triggersTest plan
make buildsucceeds (verified locally)🤖 Generated with Claude Code