Automattic / Automattic/jetpack
WP.com block editor: Revisit the date-based cache-busters [5]
- Dominant language
- PHP
- Stars
- 1.8k
- Forks
- 898
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 774
Description
https://github.com/Automattic/jetpack/pull/12070#discussion_r277117371
In order to ensure that Jetpack users download the latest version of the WP.com block editor scripts, we use a cache-buster that changes every day (https://github.com/Automattic/jetpack/pull/12245).
This will make sure that any change we make to the scripts, will reach to the Jetpack users within 24 hours. This is fine for the initial launch period, if we discover more edge issues.
But once the code reaches a stable point people would be needlessly re-downloading the script.
Let's revisit this approach once we have some stability and switch to a hash-based approach that will avoid downloading the same script when the requested version bumps even though the source scripts have not.
Contributor guide
Research direction
Read the discussion in PR 12070 and the date-based cache-buster introduced by PR 12245, then locate the current WP.com block editor script versioning entry point. Done means unchanged source scripts no longer trigger needless downloads when the requested version changes, while script changes still produce a new cache key.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, php, react
- Domain
- frontend, performance
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100