Skip to content
This repository has been archived by the owner on Mar 28, 2024. It is now read-only.

Commit

Permalink
fix: run formatter
Browse files Browse the repository at this point in the history
Signed-off-by: tison <[email protected]>
  • Loading branch information
tisonkun committed Nov 1, 2022
1 parent 6adc868 commit 2d5d810
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions globalClientModule.ts
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment';
import {ClientModule} from "@docusaurus/types";
import ExecutionEnvironment from '@docusaurus/ExecutionEnvironment'
import {ClientModule} from '@docusaurus/types'

const module: ClientModule = {
onRouteDidUpdate({location, previousLocation}) {
if (ExecutionEnvironment.canUseDOM) {
if (location.pathname != previousLocation?.pathname) {
_paq.push(['setCustomUrl', location.pathname])
_paq.push(['setDocumentTitle', document.title])
_paq.push(['trackPageView'])
console.log(`path = ${location.pathname}`)
console.log(`title = ${document.title}`)
}
}
onRouteDidUpdate({location, previousLocation}) {
if (ExecutionEnvironment.canUseDOM) {
if (location.pathname != previousLocation?.pathname) {
_paq.push(['setCustomUrl', location.pathname])
_paq.push(['setDocumentTitle', document.title])
_paq.push(['trackPageView'])
console.log(`path = ${location.pathname}`)
console.log(`title = ${document.title}`)
}
}
}
}

export default module

0 comments on commit 2d5d810

Please sign in to comment.