Skip to content

Commit

Permalink
Merge pull request #29555 from ybakos/guides_layouts_and_rendering_mi…
Browse files Browse the repository at this point in the history
…nus_leading_underscore

Guides: Clarify partial local variable naming. [ci skip]
  • Loading branch information
kamipo committed Jun 24, 2017
2 parents 2477e1b + 4d433f8 commit 35a25c3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion guides/source/layouts_and_rendering.md
Original file line number Diff line number Diff line change
Expand Up @@ -1171,7 +1171,7 @@ To pass a local variable to a partial in only specific cases use the `local_assi
This way it is possible to use the partial without the need to declare all local variables.
Every partial also has a local variable with the same name as the partial (minus the underscore). You can pass an object in to this local variable via the `:object` option:
Every partial also has a local variable with the same name as the partial (minus the leading underscore). You can pass an object in to this local variable via the `:object` option:
```erb
<%= render partial: "customer", object: @new_customer %>
Expand Down

0 comments on commit 35a25c3

Please sign in to comment.