Invalidate caches after translation changes

POM Translate clears its request-local and object caches when supported strings, translations, slugs, or custom URL translations change. External integrations must ensure their own caches vary by locale and respond to the matching public events.

Useful actions include:

  • pom_translate_string_changed;
  • pom_translate_translation_changed;
  • pom_translate_slug_changed;
  • pom_translate_custom_url_translation_changed;
  • pom_translate_language_changed for request-local components.

Inspect the hook reference for the exact arguments before registering a callback.

Cache keys for rendered fragments should include the site, object identity, locale, and any other output-changing context. Never store target-language HTML under a locale-neutral key.

Purge the smallest affected entry. A translation edit should not require flushing the complete object cache or CDN when a post-and-locale cache key can be invalidated.

POM Translate cannot automatically purge every full-page cache, reverse proxy, or CDN. Configure those layers to vary by localized path and purge affected base and target routes after slug or navigation changes.

Test by warming two locale variants, editing only one translation, and requesting both again. The changed locale must refresh without replacing or invalidating unrelated language output.