nuxt-umami
Advanced tools
Comparing version 2.5.0 to 2.5.1
@@ -132,3 +132,3 @@ import { useTitle } from '@vueuse/core'; | ||
const { | ||
location: { hostname }, | ||
location: { hostname, href }, | ||
screen: { width, height }, | ||
@@ -142,2 +142,6 @@ navigator: { language }, | ||
// get `ref from url | ||
const params = new URL(href).searchParams; | ||
const pageRef = referrer || params.get('ref') || ''; | ||
const payload: PartialPayload = { | ||
@@ -148,3 +152,3 @@ screen: `${width}x${height}`, | ||
url: pageUrl, | ||
referrer, | ||
referrer: pageRef, | ||
title: pageTitle.value || title, | ||
@@ -155,3 +159,3 @@ }; | ||
payload, | ||
pageReferrer: referrer, | ||
pageReferrer: pageRef, | ||
pageUrl, | ||
@@ -158,0 +162,0 @@ }; |
{ | ||
"name": "nuxt-umami", | ||
"type": "module", | ||
"version": "2.5.0", | ||
"version": "2.5.1", | ||
"description": "Integrate Umami Analytics into Nuxt", | ||
@@ -6,0 +6,0 @@ "author": "ML <me.mlaure@gmail.com>", |
@@ -148,3 +148,3 @@ # Nuxt Umami | ||
- `url`: the path being tracked, eg `/about`, `/contact?by=phone#office`. This can be correctly inferred. Equivalent of `router.fullPath`. | ||
- `referrer`: the page referrer. This can be correctly inferred. Equivalent of `document.referrer`. | ||
- `referrer`: the page referrer. This can be correctly inferred. Equivalent of `document.referrer` or the `ref` search param in the url (eg: `example.com/?ref=thereferrer`). | ||
@@ -151,0 +151,0 @@ - `umTrackEvent(eventName, eventData)` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
23706
480