* Add og:image:width, og:image:height, and og:image:type tags. * Use og:video tags for videos. * Use 720x720 instead of 150x150 preview images for videos. * Add duration tag to JSON-LD data for videos. * Add OpenGraph tags to media assets show page. * Respect Twitter max image size limits. * Don't include OpenGraph image tags when someone shares a plain https://danbooru.donmai.us link with no tag search. This caused random potentially NSFW images to be shown when someone shared a https://danbooru.donmai.us link on social media, which could be cached for long periods of time.
Helpers
This directory contains helper functions used by views. Helpers are used for simple common functions, such as linking to users or formatting timestamps.
Helper functions are globals. If you see an unnamespaced function in a view, and it's not a Rails function, then it's probably a helper defined here.
All helper functions defined in this directory are globally available to all views. They're not limited to single views. For example, the functions in posts_helper.rb are available to all views, not just to app/views/posts.
The use of helper functions should be minimized. Partials or components are preferred for more complex widgets, or for things used in only one or two places. Helper functions should be limited to very simple things used in nearly all views.