docs/components/controller.md in graphql_rails-0.5.0 vs docs/components/controller.md in graphql_rails-0.5.1
- old
+ new
@@ -136,9 +136,24 @@
User.create(params)
end
end
```
+### *options*
+
+You can customize your queries using `options` method. So far we've added `input_format` and allowed value is `:original` which specifies to keep the field name format.
+`options` method can be used like so:
+
+```ruby
+class UsersController < GraphqlRails::Controller
+ action(:create).options(input_format: :original).permit(:full_name)
+
+ def create
+ User.create(params)
+ end
+end
+```
+
## *before_action*
You can add `before_action` to run some filters before calling your controller action. Here is an example:
```ruby