We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
01:38:16.130 | 01:38:16.130 | ./components/card.tsx 01:38:16.130 | 27:14 Error: Invalid Tailwind CSS classnames order tailwindcss/classnames-order 01:38:16.130 | 01:38:16.130 | ./components/ui/command.tsx 01:38:16.131 | 32:18 Error: Invalid Tailwind CSS classnames order tailwindcss/classnames-order 01:38:16.131 | 01:38:16.131 | info - Need to disable some ESLint rules? Learn more here: https://nextjs.org/docs/basic-features/eslint#disabling-rules 01:38:16.248 | error Command failed with exit code 1. 01:38:16.249 | info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. 01:38:16.279 | Error: Command "yarn run build" exited with 1 01:38:16.553 | BUILD_UTILS_SPAWN_1: Command "yarn run build" exited with 1
The text was updated successfully, but these errors were encountered:
You can use the eslint-plugin-tailwindcss to automatically fix that classnames order error. @shadcn already has the plugin installed
eslint-plugin-tailwindcss
Just modify the lint script in package.json like this:
lint
package.json
"scripts": { "lint": "next lint --fix", },
And then run pnpm run lint. That should fix the classname ordering
pnpm run lint
Sorry, something went wrong.
I think the problem is, the eslint plugin doesn't follow the same rules as the tailwindcss vscode extension and the prettier plugin.
Any solution to this? The problem is indeed as @Manubi commented.
I already have this:
"lint": "next lint", "lint:fix": "next lint --fix",
"lint": "next lint",
"lint:fix": "next lint --fix",
You can also add the following line to your package.json
"lint:fix": "next lint --fix"
and then execute
npm run lint:fix
No branches or pull requests
Failed to compile.
01:38:16.130 |
01:38:16.130 | ./components/card.tsx
01:38:16.130 | 27:14 Error: Invalid Tailwind CSS classnames order tailwindcss/classnames-order
01:38:16.130 |
01:38:16.130 | ./components/ui/command.tsx
01:38:16.131 | 32:18 Error: Invalid Tailwind CSS classnames order tailwindcss/classnames-order
01:38:16.131 |
01:38:16.131 | info - Need to disable some ESLint rules? Learn more here: https://nextjs.org/docs/basic-features/eslint#disabling-rules
01:38:16.248 | error Command failed with exit code 1.
01:38:16.249 | info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
01:38:16.279 | Error: Command "yarn run build" exited with 1
01:38:16.553 | BUILD_UTILS_SPAWN_1: Command "yarn run build" exited with 1
The text was updated successfully, but these errors were encountered: