holidaycheck / react-google-tag-manager

This repository contains a react based implementation for Google's Tag Manager snippet.
MIT License
192 stars 31 forks source link

Optimize hide script #59

Closed robhuzzey closed 7 years ago

robhuzzey commented 7 years ago

Whilst implementing this plugin, I came across the issue of page flickering & found this article explaining how to resolve it: https://support.google.com/360suite/optimize/answer/6262084?visit_id=1-636174373804386974-3352179142&rd=1#page-hiding

This pull request enables us to pass in the useoptimizehide parameter to include the snippet for this script (see: https://support.google.com/360suite/optimize/answer/7100284#how-it-works)

robhuzzey commented 7 years ago

Thinking about this some more... I'm not totally sure if this is the best approach as it's mixing concerns. Just because you have google tag manager, doesn't mean you will use google optimize.

Thoughts?

robhuzzey commented 7 years ago

Closing this PR as I feel it was the wrong approach.