notifIt version 2 (https://github.com/naoxink/notifIt)
- No dependencies
- Simple
- Quick setup
- Customizable
- Size less than 4kb
Note:
notif_prompt
andnotif_confirm
are not included yet.
It's quite simple, you only have to include the .js
and .css
files in your HTML.
<link rel="stylesheet" href="notifit.min.css">
and
<script src="notifit.min.js"></script>
or via npm
npm i notifit2
var myNotification = notif({
'type': 'success',
'msg': 'Hello world! This is notifit 2!'
})
Key | Value type | Required | Options | Description |
---|---|---|---|---|
type | string |
No | success, error, info, warning | Notification type (color) |
msg | string |
No | Message you want to display | |
position | string |
No | top-right , top-center , top-left , bottom-right , bottom-center , bottom-left |
Position in the document (default: top-right ) |
opacity | number |
No | Notification opacity | |
zindex | number |
No | Personal z-index | |
callback | function |
No | Function that is executed when notification get dismissed | |
clickable | boolean |
No | true, false | Allows to click the notification without dismiss it |
Do not hesitate to leave your feedback here
All contributions are welcome :)