@bolt/components-smooth-scroll

5.8.0 • Public • Published

patternType: "smooth scroll"

Smooth Scroll

Including this component will apply smooth scroll behavior to all anchor links on a page.

Usage

  • When using a fixed header, you can avoid scrolling past anchors (and hiding the start of the content under the fixed header) by adding the class js-bolt-smooth-scroll-offset to the fixed header element itself.
  • To disable smooth scrolling for an individual link, add the data-scroll-ignore to the link attributes.
  • TODO: Document additional link-specific options.

Dependencies (3)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i @bolt/components-smooth-scroll

    Weekly Downloads

    11

    Version

    5.8.0

    License

    MIT

    Unpacked Size

    26.7 kB

    Total Files

    9

    Last publish

    Collaborators

    • mikemai2awesome
    • evanlovely
    • remydenton
    • dmorse
    • colbycook