5 ms·
FWIW Tailwind can be used as a standalone executable. This is how Phoenix/Elixir bundles Tailwind without requiring npm.
by arcanemachiner 2y ago
FWIW Tailwind can be used as a standalone executable.
This is how Phoenix/Elixir bundles Tailwind without requiring npm.
- jitl 2y agoI don’t care how you do it, just make getting your dependencies deterministic based on files committed to your repo! Happily the Tailwind hex package encourages you configure a fixed version number, so you’ll never get surprise breakage as long as you’re committing your mix.lock file as well. I’m only suggesting package.json/package-lock.json because their projects are already using the npm ecosystem to fetch the tailwind dependency. A Makefile that does `curl $TAILWIND_GITHUB_RELEASE_URL -o ./departing/tailwind` is fine too (this is what Tailwind.hex is doing under the hood).
- preisschild 2y agoAFAIK using the tailwindcss-cli without npm makes it impossible to use Tailwind plugins, such as DaisyUI.
- arcanemachiner 2y agoI believe that is true, although there is a project which bundles Tailwinds and DaisyUI into a single standalone executable: https://github.com/dobicinaitis/tailwind-cli-extra https://github.com/dobicinaitis/tailwind-cli-extra I have not tried this out yet, personally.
- J_Shelby_J 2y agoI just tried it... failed to load with very strange errors about postcss and unknown words. FWIW, the tailwind binary from the official channel works great. I install it in my build.rs.
- krnsi 2y agoThis is not true, here is a demo projects which uses the Hex Tailwind and DaisyUI: https://github.com/naymspace/backpex/tree/develop/demo https://github.com/naymspace/backpex/tree/develop/demo
- J_Shelby_J 2y agoDoesn't this still require NPM to install daisyui?