I noticed these files all had strings such as "", " ", "_" that were
allocated each time some common methods were called, over 1000x on a
page in my app. This comment freezes all of these strings such that
they're only allocated once, saving many KB of memory allocation.
This increases flexibility allowing us to yield only the builder to the
user and hiding specific details of the implementation inside it, also
reusing arguments we already know, such as attribute name and value.
This commit also adds the ability to access the current object/item in
the given collection within the builder instance, giving extra
flexibility to generate custom attributes to label/radio buttons/check
boxes.
Besides, this will make it easy for us to migrate to Rails 4 later as we
are sticking with the same concept here.
Use original config for backwards compatibility, and force label as item
wrapper tag in collection radio buttons / check boxes when using nested
boolean, to match boostrap requirements.