Version signatures

Commerce appends the version signature as a path component directly after the base URL of static view files to preserve the integrity of relative URLs across static resources.
This also forces the browser to resolve a relative URL to the correct signed source while keeping its content independent of the presence/absence of the signature value.

When a browser requests a signed source from the server, the server uses URL rewrites to strip the signature component from the URL.

Usage during deployments

After upgrading or modifying static resources, you must run the setup:static-content:deploy command to deploy the version and update the static contents, which forces the browser to load the updated resources.

If you deploy code on a separate server and move it to production using a code repository to reduce downtime, you also must add the file pub/static/deployed_version.txt to the repository.
This file contains the new version for the deployed static content.

Previous pageVarnish ESI block
Next pageCommand-line tool

Commerce