Skip to content

Commit

Permalink
feat(site): Add @vercel/analytics
Browse files Browse the repository at this point in the history
  • Loading branch information
dengfuping committed Oct 14, 2023
1 parent 38becd3 commit 73694e6
Show file tree
Hide file tree
Showing 3 changed files with 4,457 additions and 13,274 deletions.
2 changes: 2 additions & 0 deletions .dumi/theme/layouts/GlobalLayout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { App, theme as obTheme } from '@oceanbase/design';
import type { DirectionType } from '@oceanbase/design/es/config-provider';
import { usePrefersColor, createSearchParams, useOutlet, useSearchParams } from 'dumi';
import React, { useCallback, useEffect, useMemo } from 'react';
import { Analytics } from '@vercel/analytics/react';
import useLayoutState from '../../hooks/useLayoutState';
import SiteThemeProvider from '../SiteThemeProvider';
import useLocation from '../../hooks/useLocation';
Expand Down Expand Up @@ -135,6 +136,7 @@ const GlobalLayout: React.FC = () => {
onChange={nextTheme => updateSiteConfig({ theme: nextTheme })}
/>
)}
<Analytics />
</App>
</SiteThemeProvider>
</SiteContext.Provider>
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@
"@types/react": "^18.2.25",
"@umijs/fabric": "^4.0.1",
"@umijs/test": "^4.0.79",
"@vercel/analytics": "^1.1.1",
"antd": "^5.9.0",
"antd-style": "^3.5.0",
"antd-token-previewer": "^1.1.0",
Expand Down
Loading

0 comments on commit 73694e6

Please sign in to comment.