Discussions

Ask a Question
Back to All

rendering in haml

hi, I am triying to render a custom content type called posts in the index page, I choose HAML so I 'm getting this error:

undefined local variable or method `contents' for #

My code to render is:

%ul

  • contents.posts.each do |post|
    %li
    = post.title

regards