# vue-simple-snackbar

> A snackbar for vue2+ projects

Latest version **0.0.9** (published 2019-05-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install vue-simple-snackbar
pnpm add vue-simple-snackbar
yarn add vue-simple-snackbar
bun add vue-simple-snackbar
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.9 |
| Published | 2019-05-10 |
| First published | 2019-04-22 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 27 |
| Unpacked size | 21.4 KB |
| Known vulnerabilities | 0 (+9 in 4 direct dependencies) |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Eric Mendes Dantas |
| Maintainers | ericmdantas |
| Keywords | vue, snackbar |

## Links

- npm: https://www.npmjs.com/package/vue-simple-snackbar
- Repository: https://github.com/ericmdantas/vue-simple-snackbar
- Homepage: https://github.com/ericmdantas/vue-simple-snackbar#readme
- Issues: https://github.com/ericmdantas/vue-simple-snackbar/issues
- npm.io page: https://npm.io/package/vue-simple-snackbar

## Dependencies (27)

- [vue](https://npm.io/package/vue.md) ^2.2.10
- [jest](https://npm.io/package/jest.md) ^23.6.0
- [ubus](https://npm.io/package/ubus.md) ^1.0.9
- [webpack](https://npm.io/package/webpack.md) ^4.27.1
- [vue-jest](https://npm.io/package/vue-jest.md) ^3.0.1
- [node-sass](https://npm.io/package/node-sass.md) ^4.12.0
- [babel-core](https://npm.io/package/babel-core.md) ^7.0.0-bridge.0
- [babel-jest](https://npm.io/package/babel-jest.md) ^23.6.0
- [css-loader](https://npm.io/package/css-loader.md) ^1.0.1
- [vue-loader](https://npm.io/package/vue-loader.md) ^15.0.0
- [@babel/core](https://npm.io/package/@babel/core.md) ^7.2.0
- [file-loader](https://npm.io/package/file-loader.md) ^0.9.0
- [sass-loader](https://npm.io/package/sass-loader.md) ^7.1.0
- [webpack-cli](https://npm.io/package/webpack-cli.md) ^3.1.2
- [babel-loader](https://npm.io/package/babel-loader.md) ^8.0.4
- [webpack-merge](https://npm.io/package/webpack-merge.md) ^4.1.4
- [vue-test-utils](https://npm.io/package/vue-test-utils.md) ^1.0.0-beta.11
- [@vue/test-utils](https://npm.io/package/@vue/test-utils.md) ^1.0.0-beta.29
- [vue-style-loader](https://npm.io/package/vue-style-loader.md) ^4.1.2
- [@babel/preset-env](https://npm.io/package/@babel/preset-env.md) ^7.2.0
- [vue-hot-reload-api](https://npm.io/package/vue-hot-reload-api.md) ^2.0.8
- [webpack-dev-server](https://npm.io/package/webpack-dev-server.md) ^3.1.10
- [jest-serializer-vue](https://npm.io/package/jest-serializer-vue.md) ^2.0.2
- [vue-template-compiler](https://npm.io/package/vue-template-compiler.md) ^2.2.6
- [mini-css-extract-plugin](https://npm.io/package/mini-css-extract-plugin.md) ^0.4.5
- [uglifyjs-webpack-plugin](https://npm.io/package/uglifyjs-webpack-plugin.md) ^2.0.1
- [optimize-css-assets-webpack-plugin](https://npm.io/package/optimize-css-assets-webpack-plugin.md) ^5.0.1

## Alternatives

- [update-check](https://npm.io/package/update-check.md) — 4.0M weekly downloads
- [react-native-onesignal](https://npm.io/package/react-native-onesignal.md) — 134.5K weekly downloads
- [react-redux-toastr](https://npm.io/package/react-redux-toastr.md) — 33.7K weekly downloads
- [@nocobase/plugin-notification-manager](https://npm.io/package/@nocobase/plugin-notification-manager.md) — 2.0K weekly downloads
- [react-simple-toasts](https://npm.io/package/react-simple-toasts.md) — 1.9K weekly downloads

## Recent versions

- 0.0.9 (latest) — 2019-05-10
- 0.0.7 — 2019-05-08
- 0.0.6 — 2019-04-26
- 0.0.5 — 2019-04-26
- 0.0.4 — 2019-04-22
- 0.0.3 — 2019-04-22
- 0.0.2 — 2019-04-22

## README

# vue-simple-snackbar

[![Build](https://travis-ci.org/ericmdantas/vue-simple-snackbar.svg?branch=master)](https://travis-ci.org/ericmdantas/vue-simple-snackbar)

### Install

```shell
$ npm i --save vue-simple-snackbar
```

### Usage in components

```js
// app.vue

<template>
    <div>   
        <SimpleSnackbar />
    </div>
</template>

<script>
import Vue from 'vue'
import VueSimpleSnackbar from 'vue-simple-snackbar'

Vue.use(VueSimpleSnackbar)

export default {
    mounted() {
        setTimeout(() => {
            this.$simpleSnackbar.show({
                message: 'Hooray!',
                timeToHide: 30000,
                primaryAction: {
                    description: `I'm a button`,
                    action: () => alert('hello'),
                },
            })
        }, 1000)
    }
}
</script>
```

### Usage in other files

```js
// my_service.js
import {simpleSnackbar} from 'vue-simple-snackbar'

export default {
    doSomething() {
        simpleSnackbar.show({
            message: 'Hooray!',
            primaryAction: {
                description: `I'm a button`,
                action: () => alert('hello'),
            },
        })
    }
}
```

### Methods

```js
this.$simpleSnackbar.show({
    message: 'Hooray!',
    primaryAction: {
        description: `I'm a button`,
        action: () => alert('hello')
    }
})

this.$simpleSnackbar.hide()
```

### License

MIT

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