Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
<%= image_tag(@post.user.avatar.tiny.url) if @post.user.avatar? %>
submitted <%= time_ago_in_words(@post.created_at) %> ago by <%= %>
<p><%= markdown @post.body %></p>
<%= image_tag(posts.image.thumb.url) %>
<div class="col-md-4">
<% if policy(@post).update? %>
<%= link_to "Edit", new_post_path(@post), class: 'btn btn-success' %>
<p><%= @post.body %></p>
<% end %>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment