json_builder 2.0.0 → 2.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +3 -3
- data/lib/json_builder/template.rb +1 -1
- data/lib/json_builder/version.rb +1 -1
- metadata +3 -3
data/README.md
CHANGED
@@ -23,7 +23,7 @@ Second, make sure your controller responds to `json`:
|
|
23
23
|
end
|
24
24
|
end
|
25
25
|
|
26
|
-
Lastly, create `app/views/posts/index.
|
26
|
+
Lastly, create `app/views/posts/index.json_builder` which could look something like:
|
27
27
|
|
28
28
|
json.posts do
|
29
29
|
json.array! @posts do
|
@@ -42,11 +42,11 @@ You will get something like:
|
|
42
42
|
{
|
43
43
|
"id": 1,
|
44
44
|
"name": "Garrett Bjerkhoel",
|
45
|
-
"body": "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
45
|
+
"body": "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod."
|
46
46
|
}, {
|
47
47
|
"id": 2,
|
48
48
|
"name": "John Doe",
|
49
|
-
"body": "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
49
|
+
"body": "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod."
|
50
50
|
}
|
51
51
|
]
|
52
52
|
}
|
data/lib/json_builder/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: json_builder
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 13
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 2
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 2.0.
|
9
|
+
- 1
|
10
|
+
version: 2.0.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Garrett Bjerkhoel
|