react-use-window-scroll
Advanced tools
Comparing version 1.0.8 to 1.0.9
/** | ||
* Documentation: https://devboldly.github.io/react-use-scroll/useScrollBy | ||
* See documentation: [useScrollBy](https://devboldly.github.io/react-use-window-scroll/useScrollBy) | ||
* | ||
@@ -4,0 +4,0 @@ * This hook scrolls the page by the specified vertical and horizontal amount by using the Window Web API's Window.scrollBy function. |
@@ -27,3 +27,3 @@ "use strict"; | ||
/** | ||
* Documentation: https://devboldly.github.io/react-use-scroll/useScrollBy | ||
* See documentation: [useScrollBy](https://devboldly.github.io/react-use-window-scroll/useScrollBy) | ||
* | ||
@@ -30,0 +30,0 @@ * This hook scrolls the page by the specified vertical and horizontal amount by using the Window Web API's Window.scrollBy function. |
/** | ||
* Documentation: https://devboldly.github.io/react-use-scroll/useScrollTo | ||
* See documentation: [useScrollTo](https://devboldly.github.io/react-use-window-scroll/useScrollTo) | ||
* | ||
@@ -4,0 +4,0 @@ * This hook scrolls the page to the specified page coordinates using the Window Web API's Window.scrollTo function. Smooth scrolling behavior (native to the browser) is supported by providing ScrollToOptions. |
@@ -27,3 +27,3 @@ "use strict"; | ||
/** | ||
* Documentation: https://devboldly.github.io/react-use-scroll/useScrollTo | ||
* See documentation: [useScrollTo](https://devboldly.github.io/react-use-window-scroll/useScrollTo) | ||
* | ||
@@ -30,0 +30,0 @@ * This hook scrolls the page to the specified page coordinates using the Window Web API's Window.scrollTo function. Smooth scrolling behavior (native to the browser) is supported by providing ScrollToOptions. |
{ | ||
"name": "react-use-window-scroll", | ||
"version": "1.0.8", | ||
"author": "Dev Boldly <devboldly@gmail.com>", | ||
"version": "1.0.9", | ||
"author": "DevBoldly <devboldly@gmail.com>", | ||
"description": "React hooks for scrolling the page to any location, or by any amount. Supports smooth scrolling.", | ||
"homepage": "https://github.com/devboldly/react-use-scroll#readme", | ||
"homepage": "https://github.com/devboldly/react-use-window-scroll#readme", | ||
"main": "./dist/index.js", | ||
@@ -30,6 +30,6 @@ "types": "./dist/index.d.ts", | ||
"type": "git", | ||
"url": "git+https://github.com/devboldly/react-use-scroll.git" | ||
"url": "git+https://github.com/devboldly/react-use-window-scroll.git" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/devboldly/react-use-scroll/issues" | ||
"url": "https://github.com/devboldly/react-use-window-scroll/issues" | ||
}, | ||
@@ -46,3 +46,3 @@ "keywords": [], | ||
"@babel/core": "^7.8.7", | ||
"@devboldly/react-devboldly-tools": "^1.0.14", | ||
"@devboldly/react-devboldly-tools": "^1.0.15", | ||
"@storybook/addons": "^5.3.17", | ||
@@ -76,2 +76,3 @@ "@storybook/preset-typescript": "^2.1.0", | ||
"react-test-renderer": "^16.13.0", | ||
"react-use-window-scroll": "^1.0.8", | ||
"ts-jest": "^25.2.1", | ||
@@ -78,0 +79,0 @@ "ts-loader": "^6.2.1", |
<h2 align="center"> | ||
<a href="https://github.com/devboldly/react-use-scroll">React Use Window Scroll</a> | ||
<a href="https://github.com/devboldly/react-use-window-scroll">React Use Window Scroll</a> | ||
</h2> | ||
@@ -8,10 +8,10 @@ <h3 align="center"> | ||
<p align="center"> | ||
<a href="https://badge.fury.io/js/%40devboldly%2Freact-use-scroll"> | ||
<img src="https://badge.fury.io/js/%40devboldly%2Freact-use-scroll.svg" alt="npm Version"/> | ||
<a href="https://badge.fury.io/js/react-use-window-scroll"> | ||
<img src="https://badge.fury.io/js/react-use-window-scroll.svg" alt="npm Version"/> | ||
</a> | ||
<a href="https://github.com/devboldly/react-use-scroll/actions?query=workflow%3ATests"> | ||
<img src="https://github.com/devboldly/react-use-scroll/workflows/Tests/badge.svg" alt="Tests Status"/> | ||
<a href="https://github.com/devboldly/react-use-window-scroll/actions?query=workflow%3ATests"> | ||
<img src="https://github.com/devboldly/react-use-window-scroll/workflows/Tests/badge.svg" alt="Tests Status"/> | ||
</a> | ||
<a href="https://github.com/devboldly/react-use-scroll/actions?query=workflow%3ADeploy"> | ||
<img src="https://github.com/devboldly/react-use-scroll/workflows/Deploy/badge.svg" alt="Deploy Status"/> | ||
<a href="https://github.com/devboldly/react-use-window-scroll/actions?query=workflow%3ADeploy"> | ||
<img src="https://github.com/devboldly/react-use-window-scroll/workflows/Deploy/badge.svg" alt="Deploy Status"/> | ||
</a> | ||
@@ -22,6 +22,8 @@ </p> | ||
Read the **[official documentation](https://devboldly.github.io/react-use-scroll/)**. | ||
Read the **[official documentation](https://devboldly.github.io/react-use-window-scroll/)**. | ||
👁️ **[Live Demo](https://devboldly.github.io/react-use-scroll/useScrollTo#hook-example)** | ||
[![Demo](./src/__docz__/images/demo.gif "Demo")](https://devboldly.github.io/react-use-window-scroll/useScrollTo#hook-example) | ||
👁️ **[Live Demo](https://devboldly.github.io/react-use-window-scroll/useScrollTo#hook-example)** | ||
## Overview | ||
@@ -31,4 +33,4 @@ | ||
- [useScrollBy](https://devboldly.github.io/react-use-scroll/useScrollBy) - Returns a function to scroll the page up or down by any amount, in pixels. Supports smooth scrolling. | ||
- [useScrollTo](https://devboldly.github.io/react-use-scroll/useScrollTo) - Returns a function to scroll the page to any page coordinates, in pixels. Supports smooth scrolling. | ||
- [useScrollBy](https://devboldly.github.io/react-use-window-scroll/useScrollBy) - Returns a function to scroll the page up or down by any amount, in pixels. Supports smooth scrolling. | ||
- [useScrollTo](https://devboldly.github.io/react-use-window-scroll/useScrollTo) - Returns a function to scroll the page to any page coordinates, in pixels. Supports smooth scrolling. | ||
@@ -78,3 +80,3 @@ Click either of those to see a live demo (at bottom of page). | ||
Read full [useScrollBy docs](https://devboldly.github.io/react-use-scroll/useScrollBy). | ||
Read full [useScrollBy docs](https://devboldly.github.io/react-use-window-scroll/useScrollBy). | ||
@@ -84,3 +86,2 @@ ### useScrollTo | ||
```jsx | ||
import * as React from 'react'; | ||
import { useScrollTo } from 'react-use-window-scroll'; | ||
@@ -101,3 +102,3 @@ | ||
Read full [useScrollTo docs](https://devboldly.github.io/react-use-scroll/useScrollTo). | ||
Read full [useScrollTo docs](https://devboldly.github.io/react-use-window-scroll/useScrollTo). | ||
@@ -114,2 +115,4 @@ ## TypeScript | ||
Open source software is awesome and so are you. 😎 | ||
Feel free to submit a pull request for bugs or additions, and make sure to update tests as appropriate. If you find a mistake in the docs, send a PR! Even the smallest changes help. | ||
@@ -121,5 +124,5 @@ | ||
## ⭐ Found It Helpful? [Star It!](https://github.com/devboldly/react-use-scroll/stargazers) | ||
## ⭐ Found It Helpful? [Star It!](https://github.com/devboldly/react-use-window-scroll/stargazers) | ||
If you found this project helpful, let the community know by giving it a [star](https://github.com/devboldly/react-use-scroll/stargazers): [👉⭐](https://github.com/devboldly/react-use-scroll/stargazers) | ||
If you found this project helpful, let the community know by giving it a [star](https://github.com/devboldly/react-use-window-scroll/stargazers): [👉⭐](https://github.com/devboldly/react-use-window-scroll/stargazers) | ||
@@ -126,0 +129,0 @@ ## Logo Attribution |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Non-existent author
Supply chain riskThe package was published by an npm account that no longer exists.
Found 1 instance in 1 package
57582
147
0
34
2