mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix: currentRoute
This commit is contained in:
parent
18a3e80864
commit
7346f20e96
@ -7,7 +7,7 @@ import { iframeReady, isMobile } from '.';
|
||||
window.syncPath = function() {
|
||||
const router = window.vueRouter;
|
||||
const isInIframe = window !== window.top;
|
||||
const currentDir = router.history.current.path;
|
||||
const currentDir = router.currentRoute.value.path;
|
||||
|
||||
if (isInIframe) {
|
||||
window.top.replacePath(currentDir);
|
||||
|
@ -1,6 +1,7 @@
|
||||
<template>
|
||||
<div class="app">
|
||||
<van-doc
|
||||
v-if="config"
|
||||
:lang="lang"
|
||||
:config="config"
|
||||
:versions="versions"
|
||||
@ -73,7 +74,8 @@ export default {
|
||||
},
|
||||
|
||||
created() {
|
||||
this.setTitle();
|
||||
// TODO
|
||||
// this.setTitle();
|
||||
},
|
||||
|
||||
mounted() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user