remark-emoji
Advanced tools
Comparing version 1.1.0 to 1.1.1
@@ -88,2 +88,13 @@ const assert = require('assert'); | ||
}); | ||
it('can handle emoji that use dashes to separate words instead of underscores', () => { | ||
const cases = { | ||
'The Antarctic flag is represented by :flag-aq:': 'The Antarctic flag is represented by 🇦🇶\n', | ||
':man-woman-girl-boy:': '👨👩👧👦\n' | ||
}; | ||
return Promise.all( | ||
Object.keys(cases).map(c => process(c).then(r => assert.equal(r, cases[c]))) | ||
); | ||
}); | ||
}); |
const visit = require('unist-util-visit'); | ||
const emoji = require('node-emoji'); | ||
const RE_EMOJI = /:\+1:|:-1:|:\w+:/g; | ||
const RE_EMOJI = /:\+1:|:-1:|:[\w-]+:/g; | ||
@@ -6,0 +6,0 @@ function plugin(_, settings) { |
{ | ||
"name": "remark-emoji", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "Emoji transformer plugin for Remark", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
7556
139