Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

native模式下,子应用内部跳转,不触发主应用的路由监听 #1432

Open
dengjunxx opened this issue Oct 30, 2024 · 1 comment
Assignees

Comments

@dengjunxx
Copy link

问题描述

native模式下,子应用页面A里有个button,点击跳转到页面B,路径和页面都能改变,但是在主应用的watch和路由拦截中,都监听不到路由变化

复现步骤

1.子应用页面A里有个button,点击跳转到页面B
2.路径虽然改变了,但是在主应用的watch和路由拦截中,都监听不到路由变化

上传截图

请上传代码截图、控制台、终端等截图以帮助我们了解您的问题。

复现仓库

请提供一个精简的代码仓库,然后上传到自己的 github,以帮助我们复现您的问题。
主应用:https://gitee.com/dengjunxx/micro-app_main_demo
子应用:https://gitee.com/dengjunxx/micro-app_child_vite-vue3_demo

环境信息

micro-app版本:^1.0.0-rc.9
主应用前端框架&版本: "vue": "^3.2.45",
子应用前端框架&版本: "vue": "^2.2.45",
构建工具&版本:"vite": "^4.1.0",

@timhub66 timhub66 self-assigned this Nov 1, 2024
@dengjunxx
Copy link
Author

还有几个问题,是和这个同一个项目的,有时间也一起帮忙看看吧 @timhub66

  1. 切换成native路由,但是后退按钮有时候得点击两回才能正常后退 主应用使用keep-alive对子应用保活时,有几率出现路由栈里多了一条跳转记录 #1421
  2. 子应用控制台报错:Cannot read properties of null (reading 'emitsOptions') 子应用控制台报错:Cannot read properties of null (reading 'emitsOptions') #1372

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants