I added a navbar.html.eex to my layout folder and this template is rendered from app.html.eex
<%= render "navbar.html", conn: @conn, current_user: @current_user %>
and it should point to my file: assets/css/navbar.css
But the file does not load, in my browser console I get:
GET http://localhost:4000/css/navbar.css net::ERR_ABORTED with a 404 error.
I come from the Rails world and that's how I was used to do but maybe there is another way of doing it in Phoenix. I can't find a nice doc about managing css files in Phoenix so if anybody has some readings to recommend ! I'll be grateful !elixirphoenix-framework
Ok so after I read the docs I realised Pheonix uses Brunch and gather CSS in a big app.css file in priv/static. No import needed like in Rails.
this post might help you with the configuration.
and will hopefully resolve your issues. I had the same issue when setting up my front-end and it helped me out