We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f302eeb commit bcf5795Copy full SHA for bcf5795
packages/bridge/vue3-bridge/src/create.ts
@@ -19,7 +19,7 @@ export function createRemoteComponent(info: {
19
const route = useRoute();
20
21
let basename = '/';
22
- const matchPath = route.matched[0]?.path;
+ const matchPath = route?.matched?.[0]?.path;
23
if (matchPath) {
24
if (matchPath.endsWith('/:pathMatch(.*)*')) {
25
basename = matchPath.replace('/:pathMatch(.*)*', '');
packages/bridge/vue3-bridge/src/remoteApp.tsx
@@ -56,7 +56,7 @@ export default defineComponent({
56
};
57
58
const watchStopHandle = watch(
59
- () => route.path,
+ () => route?.path,
60
(newPath) => {
61
if (newPath !== route.path) {
62
renderComponent();
0 commit comments