Skip to main content

Google Tag Manager (GTM)

Web Source code Package

Google Tag Manager (GTM) is a tool to manage and add third-party integrations to your website.

Installation

npm install @walkeros/web-destination-gtag

Setup

import { startFlow } from '@walkeros/collector';
import { destinationGtag } from '@walkeros/web-destination-gtag';

const { elb } = await startFlow();

elb('walker destination', destinationGtag, {
settings: {
gtm: {
containerId: 'GTM-XXXXXXX', // Required
dataLayer: 'dataLayer', // Optional custom dataLayer name
},
},
});

Configuration reference

PropertyTypeDescriptionMore
containerId*stringGTM Container ID from Google Tag Manager
dataLayerstringCustom dataLayer variable name
domainstringDomain for GTM script loading
* Required fields

Event Mapping

GTM specific event mapping (mapping.entity.action.settings.gtm) currently has no configurable properties. The GTMMapping interface is empty, so events are passed through to GTM without additional transformation options.

💡 Need Professional Support?
Need professional support with your walkerOS implementation? Check out our services.