Hi everyone,
I’m building an agency website and I’m using Middleman Blog for case studies. Every article has the same items in frontmatter, such as:
project: project title goes here
tags: tag 1, tag 2, tag 3
client_logos:
- first-client-logo.png
- second-client-logo.png
date: date goes here
I’ve added the following (I’m using Bootstrap):
<h1>CLIENTS</h1>
<div class="row">
<% current_article.data.client_logos.each do |logo| %>
<div class="col-xs-6">
<img class="img-responsive" src="<%= logo %>" />
</div>
<% end %>
</div>
This all works perfectly fine. What I’d like to achieve, is a condition based on the amount of client logos. To be precise: if there is just one client logo, I’d like the header to say “client” instead of “clients”.
I’m stuck - don’t know how I can do a “if client_logos > 1” statement.
Thanks!