How to integrate Batch's snippet (ECMAScript 6) using a Tag Manager?

Here is how to integrate Batch scripts using a Tag Manager that does not support the most recent JavaScript versions.

Batch methods available in our documentation (for example to collect profile data) are written in the latest available version of JavaScript. However, some Tag Management Systems do not support ECMAScript 6.

Managing compatibility issues

In some cases, Batch JavaScript tags are not supported by default by Tag managers like Google Tag Manager (GTM) and Tag Commander due to the use of arrow functions.

In order to use the preconfigured JavaScript tags in these Tag Managers, you must remove all the arrow functions it contains. This can be done easily by using a tool like Babel.

Babel

You can use our pre-configured Babel link to convert Batch tags into a JavaScript format compatible with Tag Management System tools.

Last updated

Was this helpful?