Skip to content

Latest commit

 

History

History
65 lines (43 loc) · 771 Bytes

README.md

File metadata and controls

65 lines (43 loc) · 771 Bytes

Rack::Emoji

Quickly and easily use emoji with rack based application

Installation

Add this line to your application's Gemfile:

gem 'rack-emoji'

And then execute:

$ bundle

Or install it yourself as:

$ gem install rack-emoji

Usage

To get started, need a copy of emoji images. Edit your Rakefile:

# Rakefile
load 'tasks/emoji.rake'
$ rake emoji # copied to your public directory

Edit your rack application file as follows:

require 'rack/emoji'

use Rack::Emoji, :width => 50, :height => 50

# ...

run app

Just use emoji name.

# your.html/erb/haml...
:dog:

Please see the example directory 🐶

Options

  • dir (for emoji image directory)
  • width
  • height
  • style