DEV Community

Discussion on: How to add a link to an image in Phoenix

Collapse
 
astrogreg profile image
Greg

This does not work

use this:

 <%= link to: "/" do %>
  <img src="/images/Logo_tekst.png" alt="" class="h-10 w-auto lg:h-12"/>
  <% end %>
Enter fullscreen mode Exit fullscreen mode
Collapse
 
wceolin profile image
Will Ceolin

Thanks, I had forgotten the do part after link to:. Fixed now.