1.0.5 • Published 6 years ago

alertic v1.0.5

Weekly downloads
4
License
ISC
Repository
github
Last release
6 years ago

alertic

A simple Node.js alert module.

Introduction

alertic is a tiny JavaScript module for displaying messages in different modes (success, error and warning). It accepts optional display time in seconds as input parameter. If the time is omitted, a close icon will appear on the top right corner of the box. Clicking on it will remove the box from the DOM.

Note

Please make sure that the body tag exists in your HTML.

Installation

npm install alertic --save

Usage

Javascript

var alertic = require('alertic');
const optionalDisplayTimeInSeconds = 3;
alertic.success('Your success message', optionalDisplayTimeInSeconds);
alertic.error('Your error message', optionalDisplayTimeInSeconds);

TypeScript

import { alertic, genericErrorMessage } from 'alertic';
alertic.error(genericErrorMessage);
alertic.warning('This is a warning message!');
1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.0

6 years ago