xuclfa
Last Updated: February 25, 2016
·
1.037K
· edelpero

Strong Parameters the Right Way

Use ActionParameter gem to handle your parameters.

Checkout this article with a comparison of the current patterns used to work with Strong Parameters.

3 Responses
Add your response

10177

I think it's better to handle parameters in form class. What do you think?

over 1 year ago ·
10187

What exactly would be a form class? If you mean something like Reform gem, you'll be coupling you parameters logic in a form class, and the form would be knowing too much and so you'll be breaking the Single Responsability Principle.

over 1 year ago ·
18198

What makes the gem better than just using strong parameters the regular way we know it to be. If I'm too lazy to list all the parameters, I use the permit!

over 1 year ago ·