質問編集履歴

2

Ruby構文からHTMLへ変更

2020/08/18 03:42

投稿

ammy
ammy

スコア1

test CHANGED
File without changes
test CHANGED
@@ -8,19 +8,15 @@
8
8
 
9
9
  <div class="card__body">
10
10
 
11
- <% @posts.each do |post| %>
12
-
13
- <%= image_tag post.image, class:"posted_pic" %>
11
+ < img="/post.image" class="posted_pic">
14
12
 
15
13
  <div class="card__text">
16
14
 
17
- <div class="card__title"><%= post.post_title %></div>
15
+ <div class="card__title">post.post_title</div>
18
16
 
19
- <div class="card__user"><%= post.user.nickname %></div>
17
+ <div class="card__user">post.user.nickname</div>
20
18
 
21
19
  </div>
22
-
23
- <% end %>
24
20
 
25
21
  </div>
26
22
 
@@ -28,9 +24,9 @@
28
24
 
29
25
  </div>
30
26
 
31
- <%= link_to "投稿する", new_cat_main_path %>
32
27
 
28
+
33
- </div>
29
+ <div>投稿する</div>
34
30
 
35
31
 
36
32
 

1

ご指摘のタグ部分の変更

2020/08/18 03:42

投稿

ammy
ammy

スコア1

test CHANGED
File without changes
test CHANGED
File without changes