Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

String selectors broken in Typography plugin after upgrading to Tailwind CSS v4 #384

Open
faiz9068 opened this issue Feb 20, 2025 · 0 comments

Comments

@faiz9068
Copy link

What version of @tailwindcss/typography are you using?

"^0.5.16"

What version of Node.js are you using?

v22.13.1

What browser are you using?

chrome

What operating system are you using?

windows

Reproduction repository

.

Describe your issue

Description

After upgrading to Tailwind CSS v4, previously working string selectors in the Typography plugin configuration now cause PostCSS "Unknown word" errors. This appears to be a regression as these selectors worked in v3.x.

Previously Working Code (Tailwind CSS v3.x)

typography: {
  DEFAULT: {
    css: {
      "pre code": false,
      "code::before": false,
      "code::after": false
    }
  }
}

Error After v4 Upgrade

[ERROR] [postcss] Unknown word
  Stack trace:
    at Input.error (node_modules\postcss\lib\input.js:109:16)

Steps to Reproduce

  1. Upgrade from Tailwind CSS v3.x to v4
  2. Use string selectors in Typography plugin configuration

Additional Information

  • This worked in Tailwind CSS v3.x
  • Affects all string selectors in Typography configuration
  • Appears to be a regression rather than intended behavior
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant