📜  vue scrollbehavior typescript 代码示例

📅  最后修改于: 2022-03-11 14:48:31.093000             🧑  作者: Mango

代码示例2
scrollBehavior (to, from, savedPosition) {
  if (to.hash) {
    return {
      selector: to.hash,
      behavior: 'smooth',
    }
  }
}