refactor(layout): 优化外部链接跳转逻辑

- 移除了不必要的 router.resolve 调用- 直接使用 path.value作为外部链接地址 -简化了代码结构,提高了性能

Signed-off-by: mazeyang1 <1834413471@qq.com>
pull/88/head
mazeyang1 2025-04-09 06:55:25 +00:00 committed by Gitee
parent 591fcb94ed
commit ab8d35d0ea
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 1 additions and 3 deletions

View File

@ -76,9 +76,7 @@ const changeApp = item => {
window.open(href, '_blank');
} else {
if (isExternalLink(path.value)) {
const { href } = router.resolve({
path: path.value
});
const href = path.value;
window.open(href, '_blank');
} else {
router.push(path.value);