Skip to content

Commit 0e136d8

Browse files
committed
Track playground visits properly
1 parent ddd1c1a commit 0e136d8

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

packages/typescriptlang-org/gatsby-browser.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,12 @@ exports.onRouteUpdate = ({ location, prevLocation }) => {
4646
aisdk.trackPageView({
4747
uri: locationWithoutPlaygroundCode,
4848
refUri: referrerWithoutPlaygroundCode,
49-
prev: previousLocationWithoutPlaygroundCode,
50-
lang: document.documentElement.lang,
51-
visitedPlayground:
52-
hasLocalStorage && localStorage.getItem("sandbox-history") !== null,
49+
properties: {
50+
prev: previousLocationWithoutPlaygroundCode,
51+
lang: document.documentElement.lang,
52+
visitedPlayground:
53+
hasLocalStorage && localStorage.getItem("sandbox-history") !== null,
54+
},
5355
})
5456
} catch (error) {
5557
console.error("Error with Application Insights")

0 commit comments

Comments
 (0)