Skip to content

Commit

Permalink
Update _app.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
mihaisc authored May 26, 2024
1 parent 1acb673 commit 5eab96f
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions src/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,21 +15,9 @@ import MarketMetadataProvider from '@context/MarketMetadata'
import { WagmiConfig } from 'wagmi'
import { ConnectKitProvider } from 'connectkit'
import { connectKitTheme, wagmiClient } from '@utils/wallet'
import { useRouter } from 'next/router'

function MyApp({ Component, pageProps }: AppProps): ReactElement {
Decimal.set({ rounding: 1 })
const router = useRouter()

useEffect(() => {
// Track page views
const handleRouteChange = () => posthog?.capture('$pageview')
router.events.on('routeChangeComplete', handleRouteChange)

return () => {
router.events.off('routeChangeComplete', handleRouteChange)
}
}, [router.events])

return (
<>
Expand Down

0 comments on commit 5eab96f

Please sign in to comment.