Skip to content

Instantly share code, notes, and snippets.

@nandorojo
nandorojo / segment-webflow.js
Created November 2, 2019 23:27
Segment.io Analytics.js usage on Webflow
// STEP 0:
// add the segment JS web snippet with your custom segment key to your header on webflow. this is found at your webflow project's dashboard -> custom code -> header.
// STEP 1:
// in the web flow editor, click any element you want to track when clicked, go to its settings, and add custom attributes that follow this pattern:
/*
~required~ you must add a data-analytics attribute
data-analytics="YOUR_EVENT_NAME_HERE"