Sha256: 93ee5d20c2f46e40ca0aa97be7879fa31b7c0067ac42e728ca910912105e27b7

Contents?: true

Size: 1020 Bytes

Versions: 2

Compression:

Stored size: 1020 Bytes

Contents

# Volt::Notification

Implementation of the HTML5 Notification API for Volt

## Installation

Add this line to your application's Gemfile:

    gem 'volt-notification'

And then execute:

    $ bundle

Or install it yourself as:

    $ gem install volt-notification

## Usage

add the tag <:notification> to your view.

To send a notification to all users, add a NotificaitonMessage to the page._notification_messages arraymodel:

`page._notification_messages << NotificationMessage.say('Title','Body of the message')`

To send a notification to the logged in user, add a NotificationMessage to the current_user:

`Volt.current_user._notification_messages << NotificaitonMessage.say('Title','Body of the message')`

## Contributing

1. Fork it ( http://github.com/[my-github-username]/volt-notification/fork )
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
volt-notification-0.1.1 README.md
volt-notification-0.1.0 README.md