Warning: Constant ABSPATH already defined in /homepages/15/d181455829/htdocs/bottleofbrass.com/wp-config.php on line 25
Using custom image sizes in WordPress Gutenberg MediaUpload component | Bottle of Brass
Gutenberg,  Uncategorized,  WordPress

Using custom image sizes in WordPress Gutenberg MediaUpload component

add_filter( 'image_size_names_choose', 'my_custom_sizes' );
 
function my_custom_sizes( $sizes ) {
    return array_merge( $sizes, array(
        'gallery-thumb' => __( 'Gallery Thumb' ),
        'medium-square' => __( 'Medium Square' )
    ) );
}

Leave a Reply

Your email address will not be published.

 

This site uses Akismet to reduce spam. Learn how your comment data is processed.