aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ga.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/ga.js b/ga.js
index 4299af2..8439f09 100644
--- a/ga.js
+++ b/ga.js
@@ -9,7 +9,9 @@ ga('create', 'UA-658457-6', 'auto');
function locationHashChanged() {
if(/vaadin/.test(window.location.hostname)) {
- var pageViewUrl = (window.location.pathname + window.location.hash).replace('#', '/');
+ var pageViewUrl = (window.location.pathname + window.location.hash)
+ .replace(/vaadin-components\/latest\/(.+)\/demo/, 'components-examples/$1')
+ .replace('#', '/');
ga('send', 'pageview', pageViewUrl)
}
}