RubyFlow The Ruby and Rails community linklog

Removing conditionals with Array() and Array.wrap

Ruby and ActiveSupport have two handy options for casting objects into arrays which helps guarantee your code is working with arrays and helps remove conditionals and simplify code. Learn how to use the Array() and Array.wrap methods in Ruby and ActiveSupport

Post a comment

You can use basic HTML markup (e.g. <a>) or Markdown.

As you are not logged in, you will be
directed via GitHub to signup or sign in