Skip to content
This repository was archived by the owner on Oct 19, 2018. It is now read-only.

Commit 090dcdc

Browse files
authored
Update chat.rb scroll_to_bottom call
Instructions now clear that method call should be in same component as method definition, specifically `Messages` component in this case.
1 parent 5a1061f commit 090dcdc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/tutorials/chat_app.html.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -959,7 +959,7 @@ end
959959

960960
Now all we need to do is call `scroll_to_bottom` whenever our message data changes. What we need to do is hook into the `after_mount`, and `after_update` callbacks. `after_mount` runs after the initial rendering of a component, and likewise `after_update` runs after every subsequent update.
961961

962-
Add these two lines right after the param declaration in the `Message` component:
962+
Add these two lines right after the param declaration in the `Messages` component:
963963

964964
```ruby
965965
after_mount :scroll_to_bottom

0 commit comments

Comments
 (0)