0.1.19 • Published 9 years ago

toastik v0.1.19

Weekly downloads
2
License
ISC
Repository
github
Last release
9 years ago

DISCLAIMER

The library is under development. This note will disappear, when it will be usable. Description below is desirable goal. Check out roadmap

toastik

Simple dependancies-free bootstrapy-looking javascript toast notifications library.
Inspired by toastr with no desire to use jQuery or any other framework.
No css-files are required.

Developed with ES6 compiled by babel using webpack

Demo

bezdonas.github.io/toastik

Installation

toastik can be installed as an npm package:

npm install --save toastik

...or as bower package:

bower install toastik

Want something simple and old-style? Serve it from CDN, or download and host locally:

<script src="link.to.cdn/toastik.min.js"></script>

Basic usage

Setup

// import toastik after installing it as an npm-package using ES6 modules
import toastik from 'toastik';

// ...or as AMD module
var toastik = require('toastik');

If you served it from CDN or as bower package, then you'll just get your toastik as global variable.

Usage examples

// Success toast with no title
toastik.success('Hello world!');

// Warning toast
toastik.warning('Your toast has burned :(');

// Error toast with title
toastik.error('I am an error message', 'Achtung!');

// Info toast with title and custom options
toastik.info('I am going to stay here for some long time', 'Hey!', { delay: 100500 });

// toastik will also get it, if you'll pass options as second argument, without title
toastik.success('Blink!', { delay: 1000, corner: [ 'bottom', 'left' ] });

API

API docs here

0.1.19

9 years ago

0.1.18

9 years ago

0.1.17

9 years ago

0.1.16

9 years ago

0.1.15

9 years ago

0.1.14

9 years ago

0.1.13

9 years ago

0.1.12

9 years ago

0.1.11

9 years ago

0.1.10

9 years ago

0.1.9

9 years ago

0.1.8

9 years ago

0.1.7

9 years ago

0.1.6

9 years ago

0.1.5

9 years ago

0.1.4

9 years ago

0.1.3

9 years ago

0.1.2

9 years ago

0.1.1

9 years ago

0.1.0

9 years ago