0.1.0 • Published 6 years ago

@yvany/vtoast v0.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
6 years ago

vtoast

A simple toast based on Vue.js

Demo

Install

npm install @yvany/vtoast

Example

import toast from '@yvany/vtoast'

// default options
toast('Error !')

// custom options
toast({
  message: 'Error !',

  // auto close after 3000ms
  duration: 3000,

  // vue style binding
  style: {
    color: '#F56C6C',
    background: '#FEF0F0',
    border: '1px solid #FDE2E2'
  }

  // ...other html attributes
})