CSS scroll-behavior Property

The scroll-behavior property specifies whether to smoothly animate the scroll position, instead of a straight jump, when the user clicks on a link within a scrollable box.

CSS Syntax:

Property Values

auto——>Allows a straight jump “scroll effect” between elements within the scrolling box. This is default.

smooth—–> Allows a smooth animated “scroll effect” between elements within the scrolling box.

initial-—–> Sets this property to its default value. Read about initial.

inherit——> Inherits this property from its parent element. Read about inherit

Leave a comment

Your email address will not be published. Required fields are marked *