# react-quick-alert

> Lightweight react snackbar.

Latest version **1.0.1** (published 2020-08-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-quick-alert
pnpm add react-quick-alert
yarn add react-quick-alert
bun add react-quick-alert
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2020-08-15 |
| First published | 2020-02-28 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=8 |
| Dependencies | 0 |
| Unpacked size | 22.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | lilaceproductions |
| Maintainers | fwalson |

## Links

- npm: https://www.npmjs.com/package/react-quick-alert
- Repository: https://github.com/lilaceproductions/react-quick-alert
- Issues: https://github.com/lilaceproductions/react-quick-alert/issues
- npm.io page: https://npm.io/package/react-quick-alert

## Recent versions

- 1.0.1 (latest) — 2020-08-15
- 1.0.0 — 2020-02-28

## README

# react-quick-alert

> Lightweight react snackbar.

[![NPM](https://img.shields.io/npm/v/react-quick-alert.svg)](https://www.npmjs.com/package/react-quick-alert) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)

### Install

```bash
npm install --save react-quick-alert
```

### Usage
[Demo](https://calabashlabsllc.github.io/react-quick-alert)

Demo Example Code [Here](https://github.com/CalabashLabsLLC/react-quick-alert/tree/master/example)
```
  this.state = {
    alertShown: false,
    alertMessage: ''
  };
```
```
  showAlert(msg) {
    this.setState({ alertMessage: msg, alertShown: true });
  }
```
```
  resetAlert() {
    this.setState({ alertShown: false });
  } 
```
Alert's visibility and message is controlled by solely by function and String passed in by the parent so that the event can easily add customization.

For more details, check out the API below.

## Component API

`<QuickAlert>` component:

Property | Type | Default | Required | Description
-------- | ---- | ------- | -------- |-----------
time | `Number` | n/a | yes | Duration alert shows
show | `Boolean` | n/a | yes | Trigger to show alert
message | `String` | n/a | yes | Message on alert
resetAlert | `Function` | n/a | yes | Removes visibility
showStyle | `String` | n/a | yes | Class added on show
alertIdentity | `String` | n/a | yes | Unique id for snackbar


### Support or Contact

Any questions? Check out our [documentation](https://github.com/CalabashLabsLLC/react-quick-alert/blob/master/README.md) or [contact support](https://www.calabashlabs.com/contact) and we’ll help you sort it out.

## License

MIT © [calabashlabsllc](https://github.com/calabashlabsllc)

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