Skip to content

Commit

Permalink
Tiled Galleries: enqueue legacy script in footer and defer (#38928)
Browse files Browse the repository at this point in the history
Related conversation: p55Cj4-3qL-p2

Co-authored-by: =?UTF-8?q?S=C3=A9rgio=20Gomes?= <[email protected]>
  • Loading branch information
jeherve and sgomes authored Aug 16, 2024
1 parent a089574 commit 131c3a3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: enhancement

Tiled Galleries: defer loading of the Tiled Gallery script for improved performance.
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,10 @@ public static function default_scripts_and_styles() {
),
array(),
JETPACK__VERSION,
false
array(
'in_footer' => true,
'strategy' => 'defer',
)
);
wp_enqueue_style( 'tiled-gallery', plugins_url( 'tiled-gallery/tiled-gallery.css', __FILE__ ), array(), '2023-08-21' );
wp_style_add_data( 'tiled-gallery', 'rtl', 'replace' );
Expand Down

0 comments on commit 131c3a3

Please sign in to comment.