Module: Roda::RodaPlugins::Presenters::InstanceMethods

Defined in:
lib/roda/plugins/presenters.rb

Instance Method Summary collapse

Instance Method Details

#present(object, **options) ⇒ Object

Find the presenter for the given object and apply it with the given options. Raises an exception if no presenter can be found.



38
39
40
41
# File 'lib/roda/plugins/presenters.rb', line 38

def present( object, **options )
	mod = self.class.presenter_collection
	return mod.present( object, **options )
end

#present_collection(object, **options) ⇒ Object

Find the presenter for the given object and apply it with the given options. Raises an exception if no presenter can be found.



46
47
48
49
# File 'lib/roda/plugins/presenters.rb', line 46

def present_collection( object, **options )
	mod = self.class.presenter_collection
	return mod.present_collection( object, **options )
end