Socket
Book a DemoInstallSign in
Socket

dem-feels

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dem-feels

A meme based emoticon standard.

1.8.1
latest
Source
npmnpm
Version published
Maintainers
1
Created
Source

dem-feels

A meme based emoticon standard.

Build Status devDependency Status

example

const demFeels = require('dem-feels');

demFeels('hello world! feelsgd');
// => hello world! <img src="https://cdn.rawgit.com/CreaturePhil/dem-feels/master/emotes/feelsgd.png" title="feelsgd" width="50" height="50" />'

installation

$ npm install dem-feels

emotes

Visit http://creaturephil.github.io/dem-feels to see the list of emotes.

documentation

demFeels(message)

Parses the message with dem feels. Default maximum count of parsing amount of emotes is 5.

demfeels.extendEmotes(newEmotes)

Add new emotes to the default list of emotes. newEmotes is an object.

Example:

demFeels.extendEmotes({
  'feelsnew': 'feelsnew.png'
});

demFeels.getEmotes()

Get an object of emotes. For example: {'feelsgd': 'https://cdn.rawgit.com/CreaturePhil/dem-feels/master/feelsgd.png'}

demFeels.setMaxCount(count)

Set the maximum number of emotes to parse. Defaults to 5. For example, limiting it to 1 will only parse one emote:

demFeels.setMaxCount(1);
demFeels('feelsgd feelsgd');
// => '<img src="https://cdn.rawgit.com/CreaturePhil/dem-feels/master/emotes/feelsgd.png" title="feelsgd" width="50" height="50" /> feelsgd'

demFeels.setImageSize(size)

Set the size of the emotes' image. The default size is 50 pixels.

demFeels.setImageSize(40);
demFeels('hi feelsgd');
// => 'hi <img src="https://cdn.rawgit.com/CreaturePhil/dem-feels/master/emotes/feelsgd.png" title="feelsgd" width="40" height="40" />'

But setting it to 2 will parse two emotes:

demFeels.setMaxCount(2);
demFeels('feelsgd feelsgd');
// => <img src="https://cdn.rawgit.com/CreaturePhil/dem-feels/master/emotes/feelsgd.png" title="feelsgd" width="50" height="50" /> <img src="https://cdn.rawgit.com/CreaturePhil/dem-feels/master/emotes/feelsgd.png" title="feelsgd" width="50" height="50" />'

license

MIT

Keywords

emoticons

FAQs

Package last updated on 26 Dec 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.