Skip to content

The syntax @plugin "@tailwindcss/typography" is not working in Tailwind v4 during production deployment on Vercel? #415

@muamarzidan

Description

@muamarzidan

What version of @tailwindcss/typography are you using?

^4.1.12

What version of Node.js are you using?

v22.17.0

What browser are you using?

Chrome

What operating system are you using?

Winwods

Reproduction repository

Describe your issue

i got this error

"      /vercel/path0/src/app/node_modules doesn't exist or is not a directory\n" +
"      /vercel/path0/src/node_modules doesn't exist or is not a directory\n" +
'      looking for modules in /vercel/path0/node_modules\n' +
'        single file module\n' +
'          using description file: /vercel/path0/package.json (relative path: ./node_modules/@tailwindcss/typography)\n' +
'            no extension\n' +
"              /vercel/path0/node_modules/@tailwindcss/typography doesn't exist\n" +
'            .js\n' +
"              /vercel/path0/node_modules/@tailwindcss/typography.js doesn't exist\n" +
'            .json\n' +
"              /vercel/path0/node_modules/@tailwindcss/typography.json doesn't exist\n" +
'            .node\n' +
"              /vercel/path0/node_modules/@tailwindcss/typography.node doesn't exist\n" +
'            .ts\n' +
"              /vercel/path0/node_modules/@tailwindcss/typography.ts doesn't exist\n" +
"        /vercel/path0/node_modules/@tailwindcss/typography doesn't exist\n" +
"      /vercel/node_modules doesn't exist or is not a directory\n" +
"      /node_modules doesn't exist or is not a directory"



and iam try to search how to solve, and nothing. But AI said this


🔥 Why Doesn’t the Official Documentation Work in Vercel Production?

You’re correct that the official Tailwind CSS Typography documentation states this.

However, this is a Tailwind v4 feature that is still in beta/experimental stage.

Issue in Production (Vercel)

Root Cause:

The @plugin directive in CSS is a new feature introduced in Tailwind v4.

In the production build (Vercel), PostCSS/Webpack does not resolve plugins from node_modules the same way it does in development.

Error: "@tailwindcss/typography" doesn't exist — because the build system doesn’t know how to load the plugin from the CSS directive.

Result: The CSS is not generated → The website renders without styling.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions