ruby - Where to place Rails code that is not a model, view, controller or helper? -


I want to share code not related to ideas among many controllers in my Rail app where I put it in the directory structure needed?

Edit: code in question if how they present the model data

Post-text "itemprop =" text ">

If the code is similar to the modules in which utility methods can be placed in the lib folder, alternatively you have a general rule for some of your controllers. Make superclasses if they share behavior

Please post an example of that kind of code What are you thinking


Comments

Popular posts from this blog

email - PHP mail error ... failed to open stream : permission denied -

c# - ListView onScroll event -

c - Linux mmap() error -