We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
<a href="">链接 </a>
点击a标签从当前页面跳转到另一个页面 通过a标签跳转,页面就会重新加载,相当于重新打开了一个网页
页面
<router-link to=""></router-link>
通过router-link进行跳转不会跳转到新的页面,不会重新渲染,它会选择路由所指的组件进行渲染
router-link避免了重复渲染,不像a标签一样需要重新渲染减少了DOM性能的损耗。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
a标签和router-link
a标签
点击a标签从当前页面跳转到另一个页面
通过a标签跳转,
页面
就会重新加载,相当于重新打开了一个网页router-link
通过router-link进行跳转不会跳转到新的页面,不会重新渲染,它会选择路由所指的组件进行渲染
区别
router-link避免了重复渲染,不像a标签一样需要重新渲染减少了DOM性能的损耗。
The text was updated successfully, but these errors were encountered: