Growstuff/growstuff

View on GitHub
app/views/home/_discuss.html.haml

Summary

Maintainability
Test Coverage

%h2.font-weight-bold.mb-4.pb-2 Recent posts
.row
  - Post.includes(:author, :crop_posts, :crops).order(created_at: :desc).limit(6).each do |post|
    .col-lg-4.col-md-12.mb-4
      = render 'posts/preview', post: post

%p.text-right
  = link_to "#{t('.view_all')} ยป", posts_path, class: 'btn btn-block'