質問編集履歴
7
修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -60,7 +60,7 @@
|
|
60
60
|
|
61
61
|
var data = <%= @data %>;
|
62
62
|
|
63
|
-
var result = '<ul class="info">'
|
63
|
+
var result = '<ul class="info">'
|
64
64
|
|
65
65
|
data.forEach(function(e){
|
66
66
|
|
6
情報の追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -103,3 +103,31 @@
|
|
103
103
|
</script>
|
104
104
|
|
105
105
|
```
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
追記:デロッパーツールでこのような表示がありました
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
```
|
114
|
+
|
115
|
+
VM340:2 Uncaught SyntaxError: Unexpected token 'var'
|
116
|
+
|
117
|
+
at DOMEval (DOMEval.js:38)
|
118
|
+
|
119
|
+
at Function.globalEval (core.js:197)
|
120
|
+
|
121
|
+
...
|
122
|
+
|
123
|
+
|
124
|
+
|
125
|
+
var data =
|
126
|
+
|
127
|
+
var result += '<ul class="info">' ←ここを指してた
|
128
|
+
|
129
|
+
data.forEach(function(e){
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
```
|
5
test
CHANGED
File without changes
|
test
CHANGED
File without changes
|
4
情報の追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -3,6 +3,22 @@
|
|
3
3
|
|
4
4
|
|
5
5
|
何回も質問すみません。毎回同じですが、なにかわかる方は回答お願いします。
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
```log
|
10
|
+
|
11
|
+
Started GET "/news/data" for ::1 at 2020-08-16 14:50:53 +0900
|
12
|
+
|
13
|
+
Processing by NewsController#data as */*
|
14
|
+
|
15
|
+
Rendering news/data.js.erb
|
16
|
+
|
17
|
+
Rendered news/data.js.erb (Duration: 0.2ms | Allocations: 4)
|
18
|
+
|
19
|
+
Completed 200 OK in 860ms (Views: 10.4ms | ActiveRecord: 0.0ms | Allocations: 1951)
|
20
|
+
|
21
|
+
```
|
6
22
|
|
7
23
|
|
8
24
|
|
3
test
CHANGED
File without changes
|
test
CHANGED
@@ -1,4 +1,8 @@
|
|
1
|
-
NewsAPIを使いJsonデータを取得するとところまでは以前の質問で出来たのですがJqueryでjsonデータをhtmlに表示するところでもハマってしまいました。
|
1
|
+
NewsAPIを使いJsonデータを取得するとところまでは以前の質問で出来たのですがJqueryでjsonデータをhtmlに表示するところでもハマってしまいました。errorは出てませんが表示がされません。
|
2
|
+
|
3
|
+
|
4
|
+
|
5
|
+
何回も質問すみません。毎回同じですが、なにかわかる方は回答お願いします。
|
2
6
|
|
3
7
|
|
4
8
|
|
2
test
CHANGED
File without changes
|
test
CHANGED
File without changes
|
1
タグの追加
test
CHANGED
File without changes
|
test
CHANGED
File without changes
|