to_partial_path feature

Hey, I am wondering if moving forward we would like to have to_partial_path be implemented something like:

      def _to_partial_path(view = nil) #:nodoc:
begin
element = if view.nil? ActiveSupport::Inflector.underscore(ActiveSupport::Inflector.demodulize(name))
else
String(view)
end collection = ActiveSupport::Inflector.tableize(name)
"#{collection}/#{element}"
end
end

Over the old method. The main benefit is rendering partials of polymorphic types.

For example: In the display ImageController#show

= render @imaginable.to_partial_path(:show)

In the display ImageController#edit

= render @imaginable.to_partial_path(:edit)

If you guys have a better solution. I’d like to hear it.