Skip to content

Vite build on Vue project produces false-positive warning regarding Vue :deep() selector #19141

@mckennahampton

Description

@mckennahampton

What version of Tailwind CSS are you using?

v4.1.14

What build tool (or framework if it abstracts the build tool) are you using?

Vite 7.1.10, Vue 3.5.22, tailwindcss/vite 4.1.14

What version of Node.js are you using?

v22.18.0

What browser are you using?

N/A

What operating system are you using?

Linux (Ubuntu 24)

Reproduction URL

https://github.com/mckennahampton/tailwind-vite-isue

Describe your issue

@tailwindcss/vite v4.1.14 outputs console warnings during the vite build process when using @reference to bring in the CSS config file and also using a :deep() selector:

<style scoped>
@reference './style.css';

:deep(.logo) {
  background: black;
}
</style>

Found 1 warning while optimizing generated CSS: ... 'deep' is not recognized as a valid pseudo-class. Did you mean '::deep' (pseudo-element) or is this a typo?

Using tailwindcss/vite@4.1.13 does not produce any console output during build.

So far, I have not found a way to suppress the output in vite, so the only workaround I am aware of is to downgrade to 4.1.13

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