[dyad] Improve HubSpot detection logic - wrote 1 file(s)
This commit is contained in:
@@ -302,8 +302,10 @@ export async function extractMetaData(url: string, keyword?: string) {
|
|||||||
|
|
||||||
let hotjarMatch = htmlContent.match(/hjid:(\d+)/);
|
let hotjarMatch = htmlContent.match(/hjid:(\d+)/);
|
||||||
if (hotjarMatch) uniqueTrackers.set("Hotjar", hotjarMatch[1]);
|
if (hotjarMatch) uniqueTrackers.set("Hotjar", hotjarMatch[1]);
|
||||||
let hubspotMatch = htmlContent.match(/js\.hs-scripts\.com\/(\d+)\.js/);
|
let hubspotMatch = htmlContent.match(
|
||||||
if (hubspotMatch) uniqueTrackers.set("HubSpot", hubspotMatch[1]);
|
/js(?:-[a-zA-Z0-9]+)?\.hs-scripts\.com\/(\d+)\.js/
|
||||||
|
);
|
||||||
|
if (hubspotMatch) uniqueTrackers.set("HubSpot", hubspotMatch[2] || hubspotMatch[1]);
|
||||||
|
|
||||||
const detectedTracking: TrackingTool[] = Array.from(
|
const detectedTracking: TrackingTool[] = Array.from(
|
||||||
uniqueTrackers,
|
uniqueTrackers,
|
||||||
|
|||||||
Reference in New Issue
Block a user