class Frenchy::Collection
Public Instance Methods
decorate(options={})
click to toggle source
Decorate the collection using the name of the decorator inferred by the first record
# File lib/frenchy/collection.rb, line 10 def decorate(options={}) return self if none? decorator_class.decorate_collection(self, options) end
decorator_class()
click to toggle source
Compatbility for associations in draper
# File lib/frenchy/collection.rb, line 17 def decorator_class return Frenchy::ArrayDecorator if none? "#{first.class.name}Decorator".constantize end