We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
in my controller i'd like to pipe two collections of users through the same RABL template (users/index).
at the moment i have to overwrite my instance variable @users to get this working:
@users = current_account.users gon.rabl 'app/views/users/index', as: 'users' @users = @deal.users gon.rabl 'app/views/users/index', as: 'team'
i'm aware that my RABL template is using @users, would be nice if there was a way for gon.rabl to take an :object or :locals parameter, such as:
gon.rabl 'app/views/users/index', as: 'team', locals: {users: @deal.users }
The text was updated successfully, but these errors were encountered:
Nice one, I'll look what can be done with it on this weekend:) Thank you!
Sorry, something went wrong.
Done in 4.0.1, will push it soon
Here is the doc for locals with rable usage: https://github.com/gazay/gon/wiki/Usage-with-RABL
Actually just as in rabl and everywhere.
awesome! thanks a lot, especially for the exceptional swiftness. i'll try it out later today.
No branches or pull requests
in my controller i'd like to pipe two collections of users through the same RABL template (users/index).
at the moment i have to overwrite my instance variable @users to get this working:
i'm aware that my RABL template is using @users, would be nice if there was a way for gon.rabl to take an :object or :locals parameter, such as:
The text was updated successfully, but these errors were encountered: