使用a标签锚点实现顺滑效果

 

 

scroll-behavior:smooth;//使用该方法使用a标签锚点的时候会实现平滑

  

xxx.scrollIntoView({
   behavior: "smooth"     
})

  

posted @ 2022-08-18 21:07  启豪  阅读(78)  评论(0)    收藏  举报