I have an HTML Slim document and would like to know how to put an else statement if no results are found. Here is my current code:
- @books.each do |rep|
.row
.large-12.columns
.bookinfo
.name= book.name
= book.title_name
br
= mail_to author.email, author.email
br
a.phonenumber href="tel:#{ author.phone }"= author.phone
Sorry, I'm not familiar with HTML Slim at all, and I have very little experience with Ruby. Thanks in advance!
source
share