TL; DR
In what simple way can I create a view help module that I can use in many applications?
What file, where is it downloaded, how?
I'm on Rails 2.3.11.
I have a bunch of helper presentation methods. Here is an example of one of them:
def render_zip_code_fields( model_instance )
end
I have about 20 or so that I have developed over the years and often use in various applications. I would like to combine all of them into one file, which I can simply insert into the application, and then I will be able to name them in my representations.
Why not just copy and paste them into application_helper.rb? I just don't like it. It seems to be a separate file.
Actually I tried to create in /lib...
module MyViewHelpers
end
application_helper.rb ...
include MyViewHelpers
" MyViewHelpers. , ? , require my_view_helpers.rb, /lib. ,
, ?
, . , .