/ Notification

Vue.js 2 wrapper around Noty.js with native API

Vue.js 2 wrapper around Noty.js with native API

vue-notice

Updated. Fully based on Noty.js API. See Usage instruction.

Vue.js plugin accessible globally from any component to run non-blocking notifications.

Installation

More installation options on noty.js

$ npm install noty

Import vue-notice.js in the main project file

import Vue from 'vue'
import VueNotice from './vue-notice'

Vue.use(VueNotice)

// Custom config 
Vue.use(VueNotice, {
  timeout: 5000,
  layout: 'topCenter'
})

Download the latest version of styles: noty.css

@import './noty.css';

Usage

In your Vue.js components, simply call:

// Success alert
this.$notice({
     type: 'success',  // alert, success, warning, error, info/information
     text: 'Some notification text' 
 })

GitHub