# react-cursor-follow

> A react component library for cursor follower.

Latest version **2.0.0** (published 2020-08-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-cursor-follow
pnpm add react-cursor-follow
yarn add react-cursor-follow
bun add react-cursor-follow
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2020-08-27 |
| First published | 2020-08-21 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 6.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3 |
| Maintainers | oielbanna |

## Links

- npm: https://www.npmjs.com/package/react-cursor-follow
- Repository: https://github.com/oielbanna/react-cursor-follow
- Homepage: https://github.com/oielbanna/react-cursor-follow#readme
- Issues: https://github.com/oielbanna/react-cursor-follow/issues
- npm.io page: https://npm.io/package/react-cursor-follow

## Recent versions

- 2.0.0 (latest) — 2020-08-27
- 1.1.0 — 2020-08-27
- 1.0.3 — 2020-08-22
- 1.0.2 — 2020-08-22
- 1.0.1 — 2020-08-21

## README

<hr>
<div align="center">
  <h1 align="center">
    react-cursor-follow
  </h1>
</div>

<p align="center">
  <a aria-label="Size" href="v">
    <img alt="Size" src="https://img.shields.io/bundlephobia/min/react-cursor-follow">
  </a>
  <a aria-label="NPM version" href="https://www.npmjs.com/package/@react-hook/mouse-position">
    <img alt="NPM Version" src="https://img.shields.io/npm/v/react-cursor-follow">
  </a>
  <a aria-label="License" href="https://jaredlunde.mit-license.org/">
    <img alt="MIT License" src="https://img.shields.io/npm/l/react-cursor-follow">
  </a>
</p>

<pre align="center">npm i react-cursor-follow</pre>
<hr>

A modern cursor follower react component.

## Quick Start

[Check out the example on **CodeSandbox**](https://codesandbox.io/s/react-cursor-follow-example-7emj2?file=/src/App.js)

```jsx harmony
import * as React from 'react'
import Cursor from 'react-cursor-follower'

const Component = (props) => {
  return <Cursor 
	pulse
	color="#E1AD01"
	duration={1}
	size={45}
	hollow
  />
}
```

## Props

#### UseMouseOptions

| Property   | Type     | Default | Description                                                                                            |
| ---------- | -------- | ------- | ------------------------------------------------------------------------------------------------------ |
| size | `number` | `23`     | The size of the follower in px. |
| color | `string` | `black`     | Any CSS color format works. Used for either background or border-color. |
| pulse | `boolean` | `false`    | Activate infinite pulse animation. |
| hollow | `boolean` | `false`    | Follow circle becomes hollow and has border with 1px and same color as color. |
| opacity | `number` | `1`    | Range [0, 1] |
| easing | `string` | `cubic-bezier(0.18, 0.89, 0.32, 1.28)`    | CSS Easing function for follower transition. |
| duration | `number` | `0.4`    | Transition duration in seconds. |
| custom | `boolean` | `false`    | Set to true if you want to use your own CSS class. |

## LICENSE

MIT

---
_Source: https://npm.io/package/react-cursor-follow · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
