method
pick_template_extension
rails latest stable - Class:
ActionView::TemplateFinder
pick_template_extension(template_path)public
Gets the extension for an existing template with the given template_path. Returns the format with the extension if that template exists.
pick_template_extension('users/show') # => 'html.erb' pick_template_extension('users/legacy') # => "rhtml"