change tags in blog preview

This commit is contained in:
Francis 2021-05-04 17:32:58 +02:00
parent 4b06c40575
commit 444ce9ae7a
No known key found for this signature in database
GPG key ID: 071BEA4C2B10077C

View file

@ -12,8 +12,8 @@
<div class="blogpreview-tags">
<% post[:tags]&.each do |tag| %>
<!-- The following code is a bit hacky, fix when necessary -->
<a class="tag is-normal is-rounded" href=<%= "/blog/#{tag.gsub(' ', '_')}/index.html" %>>
<%= tag %>
<a class="tag is-normal is-rounded" href=<%= "/blog/#{tag.split.map(&:capitalize).join('_')}/index.html" %>>
<%= tag.split.map(&:capitalize).join(' ') %>
</a>
<% end %>
</div>