You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Following the documentation, we can use Route#options and Route#settings.
Note that difference of Route#options and Route#settings.
The options can be referred from your route, it should be set by specifing key and value on verb methods such as get, post and put. The settings can also be referred from your route, but it should be set by specifing key and value on route_setting.
Somehow, its all mixed up and data can be accessed through options, attributes and settings
params can be defined through the desc DSL and it is merged with the params DSL which is confusing
desc attributes can be accessed through options[], settings[] and like a getter e.g MyApi::routes[0].description == MyApi::routes[0].options[:description]`
Should options contains just the verb options (if any) and settings just the route options ?
Should we keep internal values somewhere else ? For instance, a user could override requirements through the desc DSL.
Thanks
The text was updated successfully, but these errors were encountered:
Following the documentation, we can use
Route#options
andRoute#settings
.Somehow, its all mixed up and data can be accessed through
options
,attributes
andsettings
params
can be defined through thedesc
DSL and it is merged with theparams
DSL which is confusingdesc
attributes can be accessed throughoptions[]
,settings[]
and like a getter e.gMyApi::routes[0].description ==
MyApi::routes[0].options[:description]`Should
options
contains just the verb options (if any) andsettings
just the route options ?Should we keep internal values somewhere else ? For instance, a user could override
requirements
through thedesc
DSL.Thanks
The text was updated successfully, but these errors were encountered: