1.0.1 • Published 5 years ago

fs-toast v1.0.1

Weekly downloads
1
License
MIT
Repository
github
Last release
5 years ago

toast-fs

A simple javascript library for displaying toast notifications. This library doesn't have any dependencies and can be used with any webpage.

CDN Links:

https://cdn.jsdelivr.net/gh/FaisalST32/fs-toast@latest/src/js/toastfs.min.js
https://cdn.jsdelivr.net/gh/FaisalST32/fs-toast@latest/src/css/toastfs.min.css

NPM

npm i fs-toast

https://www.npmjs.com/package/fs-toast

Usage:

  • To use the library you can simply add a reference to the .js file at the end of the body of your html and the .css file in the head of your html page.

  • To display a toast notification, use the following methods.

Methods:

The plugin exposes these methods that you can use:

  • toastfs.success('message') - This will display a success toast with the provided message

  • toastfs.error('message') - This will display an error toast with the provided message

  • toastfs.remove() - This will remove any toast that might be displayed.