Prepare your measurement setup for the new cache-safe data layer
GTM4WP 2.0 introduces a new option that help WordPress site owners have more reliable tracking with the cache-safe data layer option.
2.0 of this plugin keeps backward compatibility, but a few features needed a deeper change to improve performance and reliability. Device data is the clearest example. It is now detected in the browser instead of on the server, and it arrives in a data layer event of its own.
A new option addresses one of the most frequently reported issues with this #WordPress plugin: one visitor’s data reaching another visitor because a caching plugin stored the page HTML and served it to everybody. The cache-safe data layer keeps those values out of the cached page and lets the browser collect them instead. It is off by default, so nothing changes until you turn it on.
Both changes have the same consequence for your container. The values now arrive after the page view, so the tags that read them need a Custom Event trigger rather than a Page View trigger.
I have written up how the data flows in both modes and what each of the four events carries, including the differences that are easy to miss once the option is on.
