View Source Dropkick.Attachableer behaviour (dropkick v0.0.0)
This modules provides a definition to specialized uploaders that can be used to specify custom upload workflows.
A specialized uploader acts as a hook before calling the function at Dropkick and allow you to modify how the upload is handled.
Link to this section Summary
Callbacks
See Dropkick.cache/2 for more information.
Provide a default URL if no upload was found
Overrides the filename used when the attachment is stored. The original filename will still be kept as a metadata.
See Dropkick.move/2 for more information.
Defines the default prefix that will be used to store and retrieve uploads.
See Dropkick.store/2 for more information.
Defines the transformations to be applied after saving attachments.
Defines a series of validations that will be called before caching the attachment.
Link to this section Types
Link to this section Callbacks
@callback cache(upload :: Dropkick.Upload.t(), list()) :: Dropkick.Attachment.type()
See Dropkick.cache/2 for more information.
Provide a default URL if no upload was found
Overrides the filename used when the attachment is stored. The original filename will still be kept as a metadata.
@callback move(atch :: Dropkick.Attachment.t()) :: Dropkick.Attachment.type()
See Dropkick.move/2 for more information.
Defines the default prefix that will be used to store and retrieve uploads.
@callback store(upload :: Dropkick.Upload.t(), list()) :: Dropkick.Attachment.type()
See Dropkick.store/2 for more information.
@callback transforms(Dropkick.Attachment.type(), context :: map()) :: transforms()
Defines the transformations to be applied after saving attachments.
Defines a series of validations that will be called before caching the attachment.