Using Static File Signatures
Adding a digital signature to the URL of static files makes it possible for browsers to detect when a newer version of the file is available. Static files that can be tracked with digital signatures include JavaScript, CSS, images, and fonts. The signature is appended to the path directly after the base URL. If a file’s signature differs from what is currently stored in the browser’s cache, then the newer version of the file is used.
See Static content signing in the developer documentation.
The Static File Settings configuration is available only when working in developer mode.
Enable signed static files
-
On the Admin sidebar, go to Stores > Settings > Configuration.
-
In the left panel, expand Advanced and choose Developer.
-
Expand the Static Files Settings section.
-
Set Sign Static Files to
Yes
. -
When complete, click Save Config.