Skip to content

hiyali/awesome-vue-toast

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

awesome-vue-toast

🐳 awesome vue2 simple toast

npm package

  • Can be singleton
  • Programmable

Changed from AStaroverov/vue-toast

Example

Live demo

Screenshot

screenshot

Install

npm i -S awesome-vue-toast

Usage

import Toast from 'awesome-vue-toast'
...
Toast.showToast('Enjoy toast!')

Singleton

<body>
  ...
  <script src="./awesome-vue-toast/build/js/toast.js"></script>
  <script>
    ...
    Toast.showToast('Enjoy toast!')
    ...
  </script>
  ...
</body>

Option

Toast.addMessage({
  text: 'This is success type',
  type: 'success',
  dismissAfter: 3 * 1000
})
option type default other value
text String
type String info success, warning, danger
dismissAfter Int 5 * 1000 milliseconds

Development / build

npm run dev # development
npm run build # build

For customization props

props default other value description
position se n, s, nw, ne, sw, se north, south, north west, ...

Releases

No releases published

Sponsor this project

Packages

No packages published