source/Emoji/gemoji-parser/lib/gemoji-parser.rb
# Gets the image file reference for a symbol; optionally with a custom path.
# - symbol: an <Emoji::Character>, or a unicode/token/emoticon string.
# - path: a file path to sub into symbol's filename.
Gets the image file reference for a symbol; optionally with a custom path.
symbol: an , or a unicode/token/emoticon string.
path: a file path to sub into symbol's filename.
Gets the image file reference for a symbol ; optionally with a custom path . symbol : an or a unicode / token / emoticon string . path : a file path to sub into symbol ' s filename .
def image_path(symbol, path=nil)
    emoji = find(symbol)
    return nil unless emoji
    return emoji.image_filename unless path
    "#{ path.sub(/\/$/, '') }/#{ emoji.image_filename.split('/').pop }"
  end
def image_path ( symbol , path = nil ) emoji = find ( symbol ) return nil unless emoji return emoji . image_filename unless path "#{ path.sub(/\/$/, '') }/#{ emoji.image_filename.split('/').pop }" end
Gets the image file reference for a symbol; optionally with a custom path.
Gets the image file reference for a symbol ; optionally with a custom path .
symbol
path