kevinlang
Phx_gen_tailwind - easily add Tailwind to a new Phoenix 1.6+ project
Hey all,
I created a phx.gen.tailwind Mix task that adds Node + TailwindCSS to a new Phoenix project. Essentially, it does the following steps for you:
- Copy over a
package.jsonfile into yourassets/directory withtailwindcssas a dev dependency - Copy over a sane default
tailwind.config.jsto yourassets/directory - Modifies your
assets/js/app.jsfile to no longer import CSS, since we are not using ESBuild for CSS processing - Modifies your
assets/css/app.cssfile to import TailwindCSS and no longer importphoenix.css - Updates the aliases in your
mix.exsfile - Prompts to install your new NPM dependencies (tailwindcss)
Pretty much based on the PR by José.
Cheers,
Kevin
Most Liked
ambareesha7
hey thank you for your work ![]()
is it possible to add more mix commands to your library for different CSS frameworks
let’s say,
project A i wanted to add TailwindCSS
project B i wanted to add BulmaCSS,
project C i wanted to add BootstrapCSS … etc
1
Popular in Announcing
None of the current solutions worked well for me, so I went ahead and built a user management system from scratch.
This project took far...
New
Hello!
tl;dr Announcing Oban, an Ecto based job processing library with a focus on reliability and historical observability.
After spen...
New
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
New
Only 650 LOC, wrote for fun :slight_smile:
https://github.com/sunboshan/qrcode
New
What is ContEx?
A pure Elixir server-side data plotting/charting library outputting SVG.
It has nice barcharts in particular and works g...
New
Hi, I would like to tell about my initiative to further maintain and develop Waffle project which is the fork of Arc library.
The progre...
New
Ash Framework
What is Ash?
Ash Framework is a declarative, resource-oriented application development framework for Elixir. A resource can...
New
Hey everyone
i’ve developed a library for Jalaali calendar for elixir which supports converting Gregorian dates to Jalaali and vice vers...
New
Introducing assertions, the library that helps you write really great test assertions!
GitHub: GitHub - devonestes/assertions: Helpful a...
New
Hey guyz
We at @aviabird are working on a payment library in elixir/phoenix. We are targeting March 2018 to add 56 Gateways to it.
Have...
New
Other popular topics
I have an umbrella app.
Some of the apps inside depend on other apps in the umbrella, unsurprisingly.
I’m writing a test for one of the...
New
Hello!
tl;dr Announcing Oban, an Ecto based job processing library with a focus on reliability and historical observability.
After spen...
New
I have a relationship of love and hate with Elixir. Lots of things are just absolutely right, but there are some things that are kind of ...
New
Why is it that the mnesia database isn’t the most preferred database for use in Elixir/Phoenix?
New
When I run the Plug and I recompile I wind up having to use Ctrl C to quit iex and start again. Witht the help of rlwrap I can use the cu...
New
Hi folks,
Few months ago I have announced the proof-of-concept of the library to manipulate the browsers DOM objects directly from Elixi...
New
Credo is smart enough to check for (something like) this:
assert length(the_list) == 0
with this response:
Checking if an enum is empt...
New
For some reason my phoenix channels are working for me in my local dev environment, but as soon as I deploy via Docker, I get a 403 error...
New
I want to highlight html closing tags when i click a html tag. That works in .html files but doesnt work for html.eex templates. How can...
New
Hi!
Currently I want to submit a form by pressing the Enter key. However, since my input field is of type “textarea” this is just adds a...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance









