You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using the hashMode property as true and the enableAutoPageviews method to start plausible tracker in my index.tsx file.
It's working as expect when I navigate between pages with hashes, except when I use the browser back button.
When I use the browser back button, plausible tracker is tracking the destination page twice.
Example: from /test#tab to /test
Probably because of:
const page = () => trackPageview();
// Attach pushState and popState listeners
const originalPushState = history.pushState;
if (originalPushState) {
// eslint-disable-next-line functional/immutable-data
history.pushState = function (data, title, url) {
originalPushState.apply(this, [data, title, url]);
page();
};
addEventListener('popstate', page); // track the browser back behavior
}
// Attach hashchange listener
if (defaults && defaults.hashMode) {
addEventListener('hashchange', page); // track when the hash changes from #tab to no hash fragment
}
The text was updated successfully, but these errors were encountered:
I'm using the hashMode property as true and the enableAutoPageviews method to start plausible tracker in my index.tsx file.
It's working as expect when I navigate between pages with hashes, except when I use the browser back button.
When I use the browser back button, plausible tracker is tracking the destination page twice.
Example: from /test#tab to /test
Probably because of:
The text was updated successfully, but these errors were encountered: