+| [preservePageViewIdForUrl](./browser-tracker.browsertracker.preservepageviewidforurl.md) | (preserve: PreservePageViewIdForUrl) => void | Decide how the <code>pageViewId</code> should be preserved based on the URL. If set to <code>false</code>, the <code>pageViewId</code> will be regenerated on the second and each following page view event (first page view doesn't change the page view ID since tracker initialization). If set to <code>true</code> or <code>'full'</code>, the <code>pageViewId</code> will be kept the same for all page views with that exact URL (even for events tracked before the page view event). If set to <code>'pathname'</code>, the <code>pageViewId</code> will be kept the same for all page views with the same pathname (search params or fragment may change). If set to <code>'pathnameAndSearch'</code>, the <code>pageViewId</code> will be kept the same for all page views with the same pathname and search params (fragment may change). If <code>preservePageViewId</code> is enabled, the <code>preservePageViewIdForUrl</code> setting is ignored. Defaults to <code>false</code>. |
0 commit comments