instance method
to_partial_path
Ruby on Rails edge
Since v3.2.22.5Signature
to_partial_path()
Returns a string identifying the path associated with the object. ActionPack uses this to find a suitable partial to represent the object.
“‘ class Person
include ActiveModel::Conversion
end
person = Person.new person.to_partial_path # => “people/person” “‘
Source
# File activemodel/lib/active_model/conversion.rb, line 114
def to_partial_path
self.class._to_partial_path
end
Defined in activemodel/lib/active_model/conversion.rb line 114
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveModel::Conversion