Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

vanilla-back-to-top

Package Overview
Dependencies
Maintainers
1
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vanilla-back-to-top - npm Package Compare versions

Comparing version 5.0.0 to 5.0.1

2

package.json
{
"name": "vanilla-back-to-top",
"version": "5.0.0",
"version": "5.0.1",
"description": "Tiny and configurable Back To Top button with no dependencies",

@@ -5,0 +5,0 @@ "main": "dist/vanilla-back-to-top.umd.js",

@@ -19,7 +19,7 @@ # Vanilla Back To Top

```html
<script src="https://unpkg.com/vanilla-back-to-top@5.0.0/dist/vanilla-back-to-top.min.js"></script>
<script src="https://unpkg.com/vanilla-back-to-top@5.0.1/dist/vanilla-back-to-top.min.js"></script>
<script>addBackToTop()</script>
```
If you don't want to rely on [unpkg.com](https://unpkg.com/#/about), save [the file](https://unpkg.com/vanilla-back-to-top@5.0.0/dist/vanilla-back-to-top.min.js) to your project and serve it from your server:
If you don't want to rely on [unpkg.com](https://unpkg.com/#/about), save [the file](https://unpkg.com/vanilla-back-to-top@5.0.1/dist/vanilla-back-to-top.min.js) to your project and serve it from your server:
```html

@@ -61,4 +61,6 @@ <script src="/assets/vanilla-back-to-top.min.js"></script>

## Examples
## Examples of some options
In addition to styling with CSS, you can call `addBackToTop` function with many [options](#options), these are some examples:
- Change colors: <img src="https://i.pi.gy/GYQNv.png" width="65" />

@@ -88,6 +90,7 @@ ```js

## All options
## All options <a id="options">#</a>
`addBackToTop` function can be called with many options:
These are all the options you can possibly provide to `addBackToTop` function:
```js
// the values are also the default ones, so the call is equivalent to addBackToTop()
addBackToTop({

@@ -107,3 +110,2 @@ id: 'back-to-top',

```
^ All these are also default values.

@@ -110,0 +112,0 @@ |Option|Description|

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc