PageSourceSearch

https://www.anthonysautomall.com/js/gtag-datalayer-push.rinnh0khe7.js

js anthonysautomall.com collected 2026-10-09 00:49:12 UTC 1,227 bytes, 41 lines download raw bytes

1$(document).ready(function () {
2    $(document).on('click', '[data-gtm-event-name]', function () {
3
4        //get all data attributes
5        var allData = $(this).data();
6        var gtagData = {};
7
8        //gtag event name
9        var eventName = $(this).attr("data-gtm-event-name");
10
11        //get only gtag dataLayer data
12        $.each(Object.keys(allData), function () {
13            if (this.startsWith('gtm')) {
14
15                if (this != 'gtmEventName') {
16                    gtagData[this] = allData[this];
17                }
18            }
19        });
20
21        const payload = {
22            event: eventName,
23            ...gtagData
24        };
25
26        window.internalDataLayer = window.internalDataLayer || [];
27        window.dataLayer = window.dataLayer || [];
28        var _layers = ['internalDataLayer', 'dataLayer'];
29        for (var _i = 1; window['dataLayer' + _i]; _i++) {
30            _layers.push('dataLayer' + _i);
31        }
32        _layers.forEach(function (_name) {
33            if (window[_name] && typeof window[_name].push === 'function') {
34                window[_name].push({...payload});
35            }
36        });
37
38        //For test
39        //console.log("DataLayer Push:", payload);
40    });
41});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.