Automattic / Automattic/jetpack

Carousel resources and inline code should only be included where needed

Open
#18,774 4 comments 0 reactions 0 assignees View on GitHub
[Feature] Carousel [Focus] Performance [Pri] Normal Enhancement
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

The inline code, stylesheet and scripts required for carousels are included on every page, resulting in PageSpeed issues like "unused JavaScript" and "unused CSS".

Unless the page contains a gallery, there's no need to include these.

Contributor guide

Open the contributing guide

Research direction

Start by locating where carousel inline code, stylesheets, and scripts are enqueued, then trace how the page can be identified as containing a gallery. Verify that carousel resources are omitted on pages without galleries while remaining available on gallery pages, and check the resulting asset usage with the relevant PageSpeed check.

Written by the indexing model from the issue text.

Assessment

Tech stack
css, javascript, php, wordpress
Domain
frontend, performance, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.