vanilla-back-to-top

Simple and tiny Back To Top button with no dependencies. Hides when on top, scrolls up smoothly when clicked. Works equally great with Vue, React, Angular and without frameworks on Jekyll, Hugo and Hexo
36,647 270
Install
npm install vanilla-back-to-top
Latest Version:7.2.1
License:MIT
Last Updated:Jan 3, 2023
Links: GitHub  ·  npm
Maintainer: vfeskov

Vanilla Back To Top

No Dependencies File Size GitHub stars

Simple and tiny Back To Top button with no dependencies. Hides when on top, scrolls up smoothly when clicked. Works equally great with Vue, React, Angular and without frameworks on Jekyll, Hugo and Hexo

Live demo

Features

How to use

Add this to <body> of your HTML:

<script src="https://unpkg.com/vanilla-back-to-top@7.2.1/dist/vanilla-back-to-top.min.js"></script>
<script>addBackToTop({
  diameter: 56,
  backgroundColor: 'rgb(255, 82, 82)',
  textColor: '#fff'
})</script>

For alternative installation see INSTALL

See EXAMPLES

For all options see OPTIONS

License

MIT, see LICENSE

Default icon from Material Design Icons under Apache License 2.0, which only restricts re-selling the icon


Support me with a star ♥

Related Packages

peco

Static website generator for humans

1,806
@attd/front-deploy

Deploy Frontend static projects to Cloudflare Pages with a single command

1,667
dead-code-checker

Dead Code Checker is a tool for finding dead code in your JavaScript or TypeScri...

84,304 41
seo-analyzer

A library for analyze a HTML files to show all of the SEO defects

26,070 93
kronk-cms

Build static sites faster with AI. Framework detection, quality guardrails, and...

1,765 11

Version History

Version Released License
7.2.1 MIT
7.2.0 MIT
7.1.16 MIT
7.1.15 MIT
7.1.14 MIT