<h1><%= @question.question %></h1>
<h2>Comments:</h2>
<% @question.comments.each do |comment| %>
    <p><%= comment.text %></p>
    <hr/>
<% end %>
<br/>

<h2>Write a comment:</h2>
<%= form_for ([@question, @question.comments.build]) do |f| %>
    <p>
      <%= f.label :text %><br/>
      <%= f.text_area :text %>
    </p>
    <p>
      <%= f.submit %>
    </p>
<% end %>
<h1><%= @question.question %></h1>
<p>
  <%= link_to 'Edit', edit_question_path(@question) %> | 
  <%= link_to 'Delete', question_path(@question), method: :delete, data: {confirm: 'Are you sure?'} %>
</p>
<h2>Comments:</h2>
<% @question.comments.each do |comment| %>
    <p><%= comment.text %></p>
    <hr/>
<% end %>
<br/>

<h2>Write a comment:</h2>
<%= form_for ([@question, @question.comments.build]) do |f| %>
    <p>
      <%= f.label :text %><br/>
      <%= f.text_area :text %>
    </p>
    <p>
      <%= f.submit %>
    </p>
<% end %>
Add links for edit, delete to question
Add links for edit, delete to question
