Soo我的问题是这里的代码:
<a href="#section">Click Here</a>
(imagine theres lots of things here)
<h1 id="section"> HERE! </h1>
一旦我点击了一个标签,我该如何设置进入该部分的动画?就像我在向下滚动?
在你的css中你可以做:
html {
scroll-behavior: smooth;
}