Skip to content

Classes on custom Astro components aren't getting sorted #128

@ni554n

Description

@ni554n

What version of prettier-plugin-tailwindcss are you using?

v0.2.3

What version of Tailwind CSS are you using?

v3.2.7

What version of Node.js are you using?

v16.14.2 & v18.14.2

What package manager are you using?

npm & pnpm

What operating system are you using?

Linux

Reproduction URL

https://stackblitz.com/edit/node-lf1jgc?file=package.json,src%2Fpages%2Findex.astro

Run npm run format and check the order of the classes in src/pages/index.astro file

Describe your issue

In a .astro file, Tailwind classes that are specified on default HTML elements are getting sorted correctly, whereas the same classes on a custom Astro component aren't. I have both prettier-plugin-astro and prettier-plugin-tailwindcss plugin installed.

Metadata

Metadata

Assignees

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