Gathering detailed insights and metrics for dile-smooth-scroll
Gathering detailed insights and metrics for dile-smooth-scroll
Gathering detailed insights and metrics for dile-smooth-scroll
Gathering detailed insights and metrics for dile-smooth-scroll
Web Component & Mixin to create smooth scroll into elements. Based on LitElement.
npm install dile-smooth-scroll
Typescript
Module System
Node Version
NPM Version
JavaScript (100%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
2 Stars
4 Commits
1 Watchers
22 Branches
1 Contributors
Updated on Feb 19, 2025
Latest Version
1.1.1
Package Id
dile-smooth-scroll@1.1.1
Unpacked Size
32.43 kB
Size
7.92 kB
File Count
16
NPM Version
6.14.6
Node Version
12.16.1
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
2
2
This package has moved and is now available at @dile/dile-smooth-scroll. Please update your dependencies. This repository is no longer maintained.
Web Component to create smooth scrolls on the page document or in a element scrolling section. Based on LitElement.
Also this package provides a mixin to implement scrollin API functions to any component you need.
Go to DEMOS page!
1npm i dile-smooth-scroll
1<script type="module"> 2 import 'dile-smooth-scroll/dile-smooth-scroll.js'; 3</script> 4 5<dile-smooth-scroll id="scrollComponent"></dile-smooth-scroll>
This component is not representational, actually provides a simple scroll API. So, you can call it's methods to create smooth scrolls in various ways.
For example:
1 // This method do a smooth scroll to the bottom of the document. 2 document.getElementById('scrollComponent').smoothScrollToBottom(); 3 4 // This method do a smooth scroll to the top of the document. 5 document.getElementById('scrollComponent').smoothScrollToTop();
Is important to note that the component uses the Javascript native scroll API. If you need to run this component in browsers that do not support it, you will need to use a polyfill. Please find the compatibility of the scroll API in Caniuse.
In this package you will find mixins to implement the scrolling API into any component. We separate the scrolling API into two mixins because usually you need only one or other.
This Mixin includes all methods related to scroll the entire document area. These are:
To use the mixin in a Web Component you can use a code like this:
1import { DileSmoothScrollMixin } from 'dile-smooth-scroll/DileSmoothScrollMixin'; 2 3class MyOwnComponent extends DileSmoothScrollMixin(LitElement) { 4 // code of your own component 5}
This mixin implements the methods to scroll the content of a element with it's own scrolling section.
The methods included in it are:
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 0/4 approved changesets -- score normalized to 0
Reason
project is archived
Details
Reason
no SAST tool detected
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
security policy file not detected
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
101 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More