- 다양한 방법이 있을 수 있습니다.
- =>
- root 'home#index'
- end
- <%= yield %>
- home_controller.rb
- create & new (swap)
- method = 'post'
- form-data
- has_many
- belongs_to
- new.html.erb
- post_title
- post_content
- routes.rb
- update(post)
- edit.html.erb
- token (CSRF)
- home_controller.rb - update action
- find_or_create_by
- save
- home_controller :: delete action
- destroy
- routes.rb
- comments#(create, delete)
- comment_controller.rb
- Comment.new & Comment.find