module Roda::RodaPlugins::AdditionalRenderEngines::InstanceMethods
Private Instance Methods
Source
# File lib/roda/plugins/additional_render_engines.rb, line 44 def template_path(opts) orig_path = super unless File.file?(orig_path) self.opts[:additional_render_engines].each do |engine| path = super(opts.merge(:engine=>engine)) return path if File.file?(path) end end orig_path end
If the template path does not exist, try looking for the template using each of the render engines, in order, returning the first path that exists. If no template path exists for the default any or any additional engines, return the original path.
Calls superclass method