Ever want access to controller methods from your views in Rails? It's easy.
helper_method :format_something
def format_something
"abc"
end
Just expose the method using "helper_method"
Ever want access to controller methods from your views in Rails? It's easy.
helper_method :format_something
def format_something
"abc"
end
Just expose the method using "helper_method"