method
url
v7.1.3.4 -
Show latest stable
- Class:
ActiveStorage::Preview
url(**options)public
Returns the URL of the preview’s variant on the service. Raises ActiveStorage::Preview::UnprocessedError if the preview has not been processed yet.
This method synchronously processes a variant of the preview image, so do not call it in views. Instead, generate a stable URL that redirects to the URL returned by this method.