mirror of
https://github.com/ditkrg/active_model_serializers.git
synced 2026-01-23 06:16:50 +00:00
Merge pull request #1267 from hudsonsferreira/master
Fix typos on README and improve CONTRIBUTING description.
This commit is contained in:
commit
526b56e9a6
@ -47,8 +47,8 @@ Rake can be found at http://docs.seattlerb.org/rake/.
|
|||||||
|
|
||||||
To run a single test suite
|
To run a single test suite
|
||||||
|
|
||||||
rake test TEST=path/to/test.rb
|
`$ rake test TEST=path/to/test.rb`
|
||||||
|
|
||||||
which can be further narrowed down to one test:
|
Which can be further narrowed down to one test:
|
||||||
|
|
||||||
rake test TEST=path/to/test.rb TESTOPTS="--name=test_something"
|
`$ rake test TEST=path/to/test.rb TESTOPTS="--name=test_something"`
|
||||||
|
|||||||
@ -200,12 +200,12 @@ end
|
|||||||
#### Attributes
|
#### Attributes
|
||||||
|
|
||||||
It's the default adapter, it generates a json response without a root key.
|
It's the default adapter, it generates a json response without a root key.
|
||||||
Doesn't follow any specifc convention.
|
Doesn't follow any specific convention.
|
||||||
|
|
||||||
#### JSON
|
#### JSON
|
||||||
|
|
||||||
It also generates a json response but always with a root key. The root key **can't be overridden**, and will be automatically defined accordingly with the objects being serialized.
|
It also generates a json response but always with a root key. The root key **can't be overridden**, and will be automatically defined accordingly with the objects being serialized.
|
||||||
Doesn't follow any specifc convention.
|
Doesn't follow any specific convention.
|
||||||
|
|
||||||
#### JSON API
|
#### JSON API
|
||||||
|
|
||||||
@ -271,7 +271,7 @@ the serializer generator:
|
|||||||
$ rails g serializer post
|
$ rails g serializer post
|
||||||
```
|
```
|
||||||
|
|
||||||
The generated seralizer will contain basic `attributes` and
|
The generated serializer will contain basic `attributes` and
|
||||||
`has_many`/`has_one`/`belongs_to` declarations, based on the model. For example:
|
`has_many`/`has_one`/`belongs_to` declarations, based on the model. For example:
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user