Skip to content

66HEX/smooth-scroll-vanilla-js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

smooth-scroll-vanilla-js

This script provides a smooth scrolling experience for a webpage. It enables smooth scrolling both when using the mouse wheel and when clicking on navigation links to jump to different sections of the page.

Table of Contents

Features

  • Smooth Scrolling: Ensures smooth vertical scrolling for both mouse wheel interactions and link clicks.
  • Cross-Browser Support: Works across all major browsers, including Safari, Chrome, Firefox, and Internet Explorer.
  • Customizable: Allows adjustment of scrolling speed and smoothness.

Installation

  1. Clone the repository:

    git clone https://github.com/66HEX/smooth-scroll.git
  2. Include the script in your HTML file:

    <script src="path/to/smooth-scroll.js"></script>

Customization

You can customize the scrolling speed and smoothness by adjusting the parameters passed to the SmoothScroll function:

new SmoothScroll(document, speed, smooth);

License

This project is licensed under the MIT License. See the LICENSE file for details.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published