Class: ActionDispatch::Routing::Mapper

Inherits:
Object
  • Object
show all
Defined in:
lib/riiif/rails/routes.rb

Instance Method Summary collapse

Instance Method Details

#iiif_for(*resources) ⇒ Object

example

iiif_for :image


5
6
7
8
9
# File 'lib/riiif/rails/routes.rb', line 5

def iiif_for(*resources)
  options = resources.extract_options!

  Riiif::Routes.new(self, options.merge(resource: resources.first)).draw
end