-
-
Save anonymous/30c017169013ad9e7c88 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# clearly a syntax error but how would I pass in a list of multiple options? | |
shared_options = [ | |
{ :foo, { default: 'hello' } }, | |
{ :bar, { default: 'world' } }, | |
{ :baz, { required: true } } | |
] | |
method_option *shared_options | |
def some_method | |
# this method uses all of the shared_options | |
end | |
method_option *shared_options | |
def another_method | |
# this method also uses the same shared options | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment