回答編集履歴
1
修正
answer
CHANGED
@@ -21,11 +21,11 @@
|
|
21
21
|
|
22
22
|
create.js.erb
|
23
23
|
```
|
24
|
-
$("#like-button-
|
24
|
+
$("#like-button-<%= @post.id %>").html("<%= j(render partial: 'like', locals: { posts: @posts, likes: @likes, like: @like, post: @post}) %>")
|
25
25
|
|
26
26
|
```
|
27
27
|
|
28
28
|
destroy.js.erb
|
29
29
|
```
|
30
|
-
$("#like-button-
|
30
|
+
$("#like-button-<%= @post.id %>").html("<%= j(render partial: 'like', locals: { posts: @posts, likes: @likes, like: @like, post: @post}) %>")
|
31
31
|
```
|