https://github.com/asadiahmad/notico
A Powerful and beautiful Library for showing JS Notifications.
https://github.com/asadiahmad/notico
javascript javascript-library notification notification-library npm npm-library
Last synced: about 1 year ago
JSON representation
A Powerful and beautiful Library for showing JS Notifications.
- Host: GitHub
- URL: https://github.com/asadiahmad/notico
- Owner: AsadiAhmad
- License: mit
- Created: 2024-10-01T12:42:48.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-10-09T17:48:17.000Z (over 1 year ago)
- Last Synced: 2025-04-14T06:55:19.512Z (about 1 year ago)
- Topics: javascript, javascript-library, notification, notification-library, npm, npm-library
- Language: JavaScript
- Homepage:
- Size: 1.67 MB
- Stars: 32
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Notico
A Powerful and beautiful Library for showing JS Notifications
## Tech :hammer_and_wrench: Languages and Tools :
* JavaScript : Core functionality is built with JavaScript
* HTML (hidden in JavaScript) : Structure of the notification built with HTML
* CSS (hidden in JavaScript) : Styles and blur effect of the notification built with CSS
## Installation
### Via NPM (better performance) :
#### Prerequisites :
Ensure Node.js and npm are installed on your system.
* If you already have Node.js and npm installed, skip to Step 4.
#### Step 1 : Download the Nodejs
Visit [Nodejs website](https://nodejs.org/) and download latest LTS (Long Time Support) version
#### Step 2 : Install Nodejs and NPM
Just run the installer and be sure check install Nodejs and NPM.
#### Step 3 : Verify the installation
You can check if you install Nodejs and npm correctly by these commands :
```sh
node -v
```
```sh
npm -v
```
If you see version numbers, the installation was successful.
#### Step4 : Install Notico Library
You can install the npm package this command (install latest version):
```sh
npm install notico
```
Or actually using this one for specific version :
```sh
npm install notico@1.0.2
```
Then add this line into your HTML code :
```sh
```
Note: if you have a Nodejs Project for web applications it recommended to install this library with this way because this way has better performance than the other way.
### Via CDN (easy to use):
You can use this script line for using the CDN :
```sh
```
Note: If you dont work with Nodejs and NPM then use this way.
## Tutorial
### Use Function in HTML or JS Code
#### HTML use :
Create a button like this :
```sh
info
```
#### JS use :
Call that function in js :
```sh
showToast.info({});
```
## Options
You can enter your parameters :
```sh
showToast.success({
title: 'success',
message: 'This is an success message',
time: 7000
});
```
In this function you can write the title, message and time.
If no parameters are provided, default values will be used. :
Title would be the type, message would be nothing or "" and time would be 7000 ms.
If your time parameter is smaller than 2000 ms then it ignore yours and would be 2000 ms.
## License
Notico is licensed under the MIT License.