# @practical-react-hooks/use-notification

> React Hook to make web browser notification to user

Latest version **1.0.1** (published 2021-09-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install @practical-react-hooks/use-notification
pnpm add @practical-react-hooks/use-notification
yarn add @practical-react-hooks/use-notification
bun add @practical-react-hooks/use-notification
```

## 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 | 1.0.1 |
| Published | 2021-09-10 |
| First published | 2021-09-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 2.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | leebonghsk |
| Maintainers | octo908 |
| Keywords | react, hook, notification |

## Links

- npm: https://www.npmjs.com/package/@practical-react-hooks/use-notification
- Repository: https://github.com/LEEBONGHAK/practical-react-hooks.git#main
- Homepage: https://github.com/LEEBONGHAK/practical-react-hooks/tree/main#readme
- Issues: https://github.com/LEEBONGHAK/practical-react-hooks/issues
- npm.io page: https://npm.io/package/@practical-react-hooks/use-notification

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2021-09-10
- 1.0.0 — 2021-09-10

## README

# @practical-react-hooks/use-notification

React Hook to make web browser notification to user

## Installation

yarn  
```
yarn add @practical-react-hooks/use-notification
```
  
npm
```  
npm i @practical-react-hooks/use-notification
```

## Usage
  
```
import React from "react";
import useNotification from "@practical-react-hooks/use-notification";

const App = () => {
  const triggerNotif = useNotification("Can you love me?", {body: "I love you"});
  return (
    <div className="App">
      <button onClick={triggerNotif}>Hello</button>
    </div>
  );
};
```

## Arguments
  
|Argument|Type|Description|Required|
|:---:|:---:|:---:|:---:|
|title|string|Notification title|yes|
|options|objects|Notification options in notification API (https://developer.mozilla.org/en-US/docs/Web/API/notification)|no|

## Return
  
|Return value|Type|Description|
|:---:|:---:|:---:|
|fireNotif|Function|Function to make Notification|

---
_Source: https://npm.io/package/@practical-react-hooks/use-notification · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
