A lightweight helper library for Umami Analytics that provides advanced tracking capabilities with minimal configuration.
- 📊 Form Submission Tracking
Automatically tracks form submissions on your website. - 📜 Scroll Depth Tracking
Monitors how far users scroll down your pages. - 🔄 Typeform Integration
Tracks submission events from embedded Typeforms. - 📅 Calendly Event Tracking
Tracks meetings scheduled through Calendly. - 💼 HubSpot Form Tracking
Tracks HubSpot form submissions and meeting bookings. - ⚡ Lightweight and Performant
Designed to have a minimal impact on your website's performance. - 🎯 Configurable Options
Easily enable, disable, or customize specific trackers.
- Add the following scripts to your HTML:
<!-- Core script -->
<script
defer
src="https://your-umami-script-src.js"></script>
<!-- umami-helper script -->
<script
defer
src="https://cdn.jsdelivr.net/gh/vierless/umami-helper@latest/umami-helper.js"></script>- That's it! All tracking features (except scroll) are enabled by default.
Most features are enabled by default. You can use a custom configuration with options to:
- Disable specific trackers
- Change default event names
- Modify tracking thresholds
Just call the script containing the custom config right after the umami-helper script.
UmamiHelper.init({
debug: true, // Enable debug logging
tracking: {
typeform: { enabled: false }, // Disable Typeform tracking
hubspot: { enabled: false }, // Disable HubSpot tracking
scroll: {
enabled: true, // Enable Scroll-Depth tracking
thresholds: [20, 50, 80], // Custom scroll depth thresholds
eventName: 'custom_scroll_event', // Custom event name for scroll tracking
},
},
});Automatically tracks form submissions on your website.
tracking: {
forms: {
enabled: true,
eventName: 'form_submit' // Default event name
}
}Tracks how far users scroll down your pages. We disabled this by default to prevent event spamming to Umami. If you want to use it, you need to use a custom config like explained above.
tracking: {
scroll: {
enabled: true,
thresholds: [25, 50, 75], // Default thresholds
eventName: 'scroll_depth'
}
}Tracks Typeform submission events.
tracking: {
typeform: {
enabled: true,
eventName: 'typeform_submit'
}
}Tracks when users schedule meetings through Calendly.
tracking: {
calendly: {
enabled: true,
eventName: 'calendly_submit'
}
}Tracks HubSpot meeting bookings.
tracking: {
hubspot: {
enabled: true,
eventName: 'hubspot_submit'
}
}Tracks clicks on outbound links.
tracking: {
outbound: {
enabled: true,
eventName: 'outbound_link'
}
}Tracks clicks on phone (tel:) and mail (mailto:) links.
tracking: {
contactLinks: {
enabled: true,
eventName: {
phone: 'phone_link',
email: 'email_link',
},
},
}Each tracker sends specific properties with its events:
form_name: Thenameattribute of the formform_id: Theidof the formtimestamp: ISO timestamp of the event
percentage: Scroll depth percentageurl: Current page pathtimestamp: ISO timestamp
form_name: Typeformtitleform_id: Typeformidresponse_id: Typeform responseidtimestamp: ISO timestamp
form_url: Thelinkto the related Calendlyevent_id: Theidof the booked eventinvitee_id: Theidof the invitee who booked the eventtimestamp: ISO timestamp
organizer: Thenameof the event organizermeeting_date: Thedateof the booked meetingmeeting_start: ISO timestamp of meetingstart datemeeting_end: ISO timestamp of meetingend datemeeting_duration: Meetingdurationin millisecondstimestamp: ISO timestamp
url: Theurlof the clicked linktimestamp: ISO timestamp
number: Thenumberof the clicked tel: linkemail: Theemailof the clicked mailto: linktimestamp: ISO timestamp
Contributions are welcome! Feel free to fork the repository, make changes, and submit a pull request.
This project is licensed under the MIT License.
- Umami Analytics: umami.is
- CDN Source: jsdelivr.net
- Author: VIERLESS GmbH