Clean up docs

This commit is contained in:
Benjamin Fleischer 2016-08-17 16:16:13 -05:00
parent a0dd5e58cc
commit 26bcdbe44a
5 changed files with 40 additions and 34 deletions

View File

@ -1,3 +1,5 @@
[Back to Guides](../README.md)
# How to add root key
Add the root key to your API is quite simple with ActiveModelSerializers. The **Adapter** is what determines the format of your JSON response. The default adapter is the ```Attributes``` which doesn't have the root key, so your response is something similar to:

View File

@ -1,4 +1,6 @@
The AMS grape formatter relies on the existence of `env['grape.request']` which is implemeted by `Grape::Middleware::Globals`. You can meet his dependency by calling it before mounting the endpoints.
[Back to Guides](../README.md)
The ActiveModelSerializers grape formatter relies on the existence of `env['grape.request']` which is implemeted by `Grape::Middleware::Globals`. You can meet his dependency by calling it before mounting the endpoints.
In the simpliest way:

View File

@ -1,3 +1,5 @@
[Back to Guides](../README.md)
# How to test
## Controller Serializer Usage