Performant Smooth Scroll JavaScript Library – smoothie

Category: Animation , Javascript | August 2, 2020
Author: marlospomin
Views Total: 261 views
Official Page: Go to website
Last Update: August 2, 2020
License: MIT


Performant Smooth Scroll JavaScript Library – smoothie


A lightweight, performant JavaScript smooth scroll library which enables the page/anchor links to smoothly scroll between sections using Element.scrollIntoView() API.

Install & import:

Install the smoothie:

# Yarn
$ yarn add smoothie-js

$ npm install smoothie-js --save

Import it into your project.

// ES 6
import smoothie from 'smoothie';

Or load the UMD version in the HTML.

<script src=""></script>


Add the ‘data-smoothie’ attribute to the anchor links that point to different content sections within the document.

<a href="#about" class="nav-link" data-smoothie>About</a>
<a href="#portfolio" class="nav-link" data-smoothie>Portfolio</a>
<a href="#blog" class="nav-link" data-smoothie>Blog</a>
<a href="#contact" class="nav-link" data-smoothie>Contact</a>

  <!-- main -->
  <div class="container" id="about">
  <div class="container" id="portfolio">
  <div class="container" id="blog">
  <div class="container" id="contact">

Activate the library and done.




  • v1.0.6

You Might Be Interested In:

Leave a Reply