ESLint rules for Tailwind CSS
You'll first need to install ESLint:
$ npm i eslint --save-dev
Next, install eslint-plugin-tailwind
:
$ npm install eslint-plugin-tailwind --save-dev
Note: If you installed ESLint globally (using the -g
flag) then you must also install eslint-plugin-tailwind
globally.
Extend your ESLint config with tailwind config:
{
"extends": ["plugin:tailwind/recommended"]
}
html
js
, jsx
, tsx
See /example/.vscode directory for recommended project settings.
sm
, md
etc.hover
, active
etc.