Skip to content

add heartbeat ping tab tracking #18028

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Sep 22, 2021
Merged

add heartbeat ping tab tracking #18028

merged 3 commits into from
Sep 22, 2021

Conversation

peterhashair
Copy link
Contributor

Description:

When the user comes back to the original tab, will send a ping request again.

Review

@peterhashair peterhashair added not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org. Needs Review PRs that need a code review labels Sep 17, 2021
@peterhashair peterhashair added this to the 4.6.0 milestone Sep 17, 2021
@peterhashair peterhashair force-pushed the m-16459-heartbeat-trigger branch 3 times, most recently from 84a8cd3 to 302a7ef Compare September 21, 2021 12:35
@peterhashair peterhashair force-pushed the m-16459-heartbeat-trigger branch from 302a7ef to 5a5da64 Compare September 21, 2021 21:40
@peterhashair
Copy link
Contributor Author

build js

@tsteur tsteur merged commit e39f2ee into 4.x-dev Sep 22, 2021
@tsteur tsteur deleted the m-16459-heartbeat-trigger branch September 22, 2021 05:49
@tsteur
Copy link
Member

tsteur commented Sep 22, 2021

Nice, worked 👍 also tested some IEs etc.

@justinvelluppillai justinvelluppillai modified the milestones: 4.6.0, 4.5.0 Sep 24, 2021
} else if (windowAlias.detachEvent) {
windowAlias.detachEvent('onfocus', heartBeatOnFocus);
windowAlias.detachEvent('onblur', heartBeatOnBlur);
windowAlias.removeEventListener('visibilitychange', heartBeatOnVisible);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be detachEvent?

@peterhashair
Copy link
Contributor Author

@paladox thanks for that, you are absolutely right. Let me do a quick fix for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Review PRs that need a code review not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org.
Development

Successfully merging this pull request may close these issues.

Heartbeat timer ping request is not always sent (focusing away from the tab should trigger the ping request)
4 participants