Active Storage

Active Storage provides file uploads for Rails applications and is the storage mechanism for Action Text, Action Mailbox, and more.

Using Active Storage

Active Storage is installed by default in Jumpstart Pro.

Check out the GoRails screencast episodes on Active Storage and the Active Storage Rails Guide for more information on how to use Active Storage.

For production, we strongly recommend using a CDN for serving files. Active Storage processes images through Rails which can add unncessary load to your Rails application and slow down your app if you don't have a CDN in production.

Direct Uploads

Direct uploads with Active Storage are enabled by default. To enable the Javascript on a file field, simply add direct_upload: true.

<%= form.file_field :attachments, multiple: true, direct_upload: true %>

The Trix editor is also preconfigured to use direct uploads when uploading attachments.

User Avatars

Users have default avatars using Gravatar, but they may override this by uploading their own avatar. These avatars are uploaded and processed using Active Storage.

© 2019 GoRails, LLC