phoenixframework / tailwind

An installer for tailwind
MIT License
475 stars 61 forks source link

Add Tailwind CSS directives to README #6

Closed ben-maclaurin closed 2 years ago

ben-maclaurin commented 2 years ago

This might save some confusion? Took me a few minutes to realise this is part of the installation/setup.

It is mentioned in: https://tailwindcss.com/docs/installation, and could be relevant for the Phoenix section.

FrankBro commented 2 years ago

Ah, thank you for this. Was wondering why it wasn't working for me but I needed to add this.

michaelfich commented 2 years ago

I was about to put up a PR for this as well and happened to notice this one. One thing I would suggest is perhaps adding something about removing import "../css/app.css"; from the app.js file as well. The comment I had added initially on my branch was the following:

Finally, in your assets/app.js you can remove the following line so that esbuild is no longer responsible for building your css:

import "../css/app.css"

Just a thought, in case it helps.

KristerV commented 2 years ago

Took me 30min to figure this out. :( And i've installed Tailwind manually before. Just thought this was already implemented in the library itself somehow.