method

variant

Importance_1
v7.0.0 - Show latest stable - 0 notes - Class: Attachment
variant(transformations) public

Returns an ActiveStorage::Variant or ActiveStorage::VariantWithRecord instance for the attachment with the set of transformations provided. See ActiveStorage::Blob::Representable#variant for more information.

Raises an ArgumentError if transformations is a Symbol which is an unknown pre-defined variant of the attachment.

Show source
Register or log in to add new notes.