Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/chemzqm/essage

elegant way to display tips/message
https://github.com/chemzqm/essage

Last synced: about 1 month ago
JSON representation

elegant way to display tips/message

Awesome Lists containing this project

README

        

# Essage

Component fork of [sofish/essage](https://github.com/sofish/essage) with API changed.

[demo](http://chemzqm.github.io/essage/)

Deprecated not maintained any more

## Installation

Install with [component(1)](http://component.io):

$ component install chemzqm/essage

## Usage

``` js
var Essage = require('essage');

Essage.show('hello, im a message', {
timeout: 2000,
placement: 'bottom',
status: 'success'
})
```

## API

### Essage.show(msg, [options])

Show `msg` with optional options.

options:

- `timeout` hide the message in timeout ms.
- `placement` the placement can be `top` or `bottom`, by default is `top`.
- `status` could be `info` `warning` `success` `error` would add class `essage-[status]` container.

### Essage.hide()

Hide the message.

## License

MIT