Closed jafin closed 2 years ago
I have a need to inject the GTM script only after the home page video has loaded, for performance reasons. Can anyone provide an example of how this injectScript prop can be used? If it provides a way to delay script injection, I can find no examples. It's obvious injectScript: false would be declared in the initial gtmParams. But I can't visualize how I would tell the GTMProvider that injectScript should toggle to true after getting my video onLoadedData event. Thanks in advance!
Introduce prop
injectScript: boolean
The default value is true, to avoid changing existing API surface.