Skip to content
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

PerformanceTiming API used by Matomo is deprecated, use PerformanceNavigationTiming if available #17102

Closed
Findus23 opened this issue Jan 15, 2021 · 1 comment · Fixed by #17130
Assignees
Labels
c: Platform For Matomo platform changes that aren't impacting any of our APIs but improve the core itself. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical. RFC Indicates the issue is a request for comments where the author is looking for feedback. Task Indicates an issue is neither a feature nor a bug and it's purely a "technical" change.
Milestone

Comments

@Findus23
Copy link
Member

I just noticed that the PerformanceTiming API used by Matomo is deprecated and might be one day removed from browsers or only supported for backwards compatibility ("Be aware that this feature may cease to work at any time.")

See https://developer.mozilla.org/en-US/docs/Web/API/Performance/timing

The suggested replacement is the PerformanceNavigationTiming API which should be used instead

I think window.performance.getEntriesByType("navigation")[0].toJSON() gives a quick overview over the data.

Unfortunatly not all modern browsers support it yet, so I guess the replacement has to wait or both have to be supported at the same time.

@Findus23 Findus23 added Task Indicates an issue is neither a feature nor a bug and it's purely a "technical" change. RFC Indicates the issue is a request for comments where the author is looking for feedback. labels Jan 15, 2021
@tsteur tsteur added c: Platform For Matomo platform changes that aren't impacting any of our APIs but improve the core itself. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical. labels Jan 17, 2021
@tsteur tsteur added this to the 4.2.0 milestone Jan 17, 2021
@tsteur
Copy link
Member

tsteur commented Jan 17, 2021

We could check if the new API is supported to use the new API and otherwise fallback.

@sgiehl sgiehl self-assigned this Jan 21, 2021
@mattab mattab changed the title use PerformanceNavigationTiming API PerformanceTiming API used by Matomo is deprecated, use PerformanceNavigationTiming if available Feb 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: Platform For Matomo platform changes that aren't impacting any of our APIs but improve the core itself. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical. RFC Indicates the issue is a request for comments where the author is looking for feedback. Task Indicates an issue is neither a feature nor a bug and it's purely a "technical" change.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants