mirror of
https://github.com/CaiJimmy/hugo-theme-stack.git
synced 2025-02-07 04:13:31 +08:00
15 lines
416 B
TypeScript
15 lines
416 B
TypeScript
import DefaultTheme from 'vitepress/theme'
|
|
import './custom.css'
|
|
|
|
export default {
|
|
...DefaultTheme,
|
|
enhanceApp({ router }) {
|
|
const oldOnAfterRouteChanged = router.onAfterRouteChanged;
|
|
|
|
router.onAfterRouteChanged = () => {
|
|
oldOnAfterRouteChanged && oldOnAfterRouteChanged();
|
|
if (typeof _carbonads !== 'undefined')
|
|
_carbonads.refresh();
|
|
}
|
|
}
|
|
} |