[QUESTION] setScreenName to URL / Path?
Schwankenson opened this issue · 1 comments
Schwankenson commented
Hi,
I`m using firebase analytics in my Web / Native iOs / Native Android App. Now I would like to set the same screen name for all platforms, to have it in the same row in Analytics reports.
How would you do this? Does this code make sense to you? It`s only the path. The host and protocol could differ on the native apps.
let screenName = window.location.href.replace(window.location.origin, "")
FirebaseAnalytics.setScreenName({
screenName: screenName;
})
Should I add a prefix, to make sure that it is the path based screen name, and not the page location?
let screenName = "Path: " + window.location.href.replace(window.location.origin, "")
What do you think?
Schwankenson commented
This stackoverflow seems to log screen view for web apps also: How to track page view with Firebase Analytics in a web, single page app?