The error I was having in my cli when trying to compile my css with tailwind was:

'tailwindcss' is not recognized as an internal or external command

The cause was that my tailwind was upgraded.


Install postcss and postcss-cli

npm install postcss postcss-cli

And from here you can run your build script like this:

npx tailwindcss-cli@latest build ../css/main.css -o ../dist/tailwind.css