From 0e573a5fb83c22a3902eef5be44287e7179b745b Mon Sep 17 00:00:00 2001 From: Yoshiyuki Hirano Date: Fri, 15 Sep 2017 14:22:36 +0900 Subject: Update Getting Started with Rails [ci skip] --- guides/source/getting_started.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/guides/source/getting_started.md b/guides/source/getting_started.md index ecc3f95a76..7c7b3a4c01 100644 --- a/guides/source/getting_started.md +++ b/guides/source/getting_started.md @@ -1165,7 +1165,7 @@ it look as follows: ```html+erb

Edit article

-<%= form_with(model: @article) do |form| %> +<%= form_with(model: @article, local: true) do |form| %> <% if @article.errors.any? %>
@@ -1768,7 +1768,7 @@ add that to the `app/views/articles/show.html.erb`. <% end %>

Add a comment:

-<%= form_with(model: [ @article, @article.comments.build ]) do |form| %> +<%= form_with(model: [ @article, @article.comments.build ], local: true) do |form| %>

<%= form.label :commenter %>
<%= form.text_field :commenter %> @@ -1834,7 +1834,7 @@ following: <%= render @article.comments %>

Add a comment:

-<%= form_with(model: [ @article, @article.comments.build ]) do |form| %> +<%= form_with(model: [ @article, @article.comments.build ], local: true) do |form| %>

<%= form.label :commenter %>
<%= form.text_field :commenter %> @@ -1864,7 +1864,7 @@ Let us also move that new comment section out to its own partial. Again, you create a file `app/views/comments/_form.html.erb` containing: ```html+erb -<%= form_with(model: [ @article, @article.comments.build ]) do |form| %> +<%= form_with(model: [ @article, @article.comments.build ], local: true) do |form| %>

<%= form.label :commenter %>
<%= form.text_field :commenter %> -- cgit v1.2.3