{"name":"markdown-it-emoji","version":"2.0.2","description":"Emoji plugin for markdown-it markdown parser.","keywords":["markdown-it-plugin","markdown-it","markdown","emoji","emojies","emoticon","emoticons"],"repository":{"type":"git","url":"git+https://github.com/markdown-it/markdown-it-emoji.git"},"license":"MIT","scripts":{"lint":"eslint .","test":"npm run lint && nyc mocha","coverage":"npm run test && nyc report --reporter html","report-coveralls":"nyc report --reporter=text-lcov | coveralls","browserify":"rollup -c support/rollup.config.js"},"devDependencies":{"@rollup/plugin-commonjs":"^15.1.0","@rollup/plugin-json":"^4.1.0","@rollup/plugin-node-resolve":"^9.0.0","coveralls":"^3.1.0","eslint":"^7.11.0","markdown-it":"^12.0.0","markdown-it-testgen":"~0.1.0","mocha":"8.1.3","nyc":"^15.1.0","rollup":"^2.29.0","rollup-plugin-terser":"^7.0.2"},"gitHead":"06cfe05c18db1984d49156bdc5625afebfe41b43","bugs":{"url":"https://github.com/markdown-it/markdown-it-emoji/issues"},"homepage":"https://github.com/markdown-it/markdown-it-emoji#readme","_id":"markdown-it-emoji@2.0.2","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-zLftSaNrKuYl0kR5zm4gxXjHaOI3FAOEaloKmRA5hijmJZvSjmxcokOLlzycb/HXlUFWzXqpIEoyEMCE4i9MvQ==","shasum":"cd42421c2fda1537d9cc12b9923f5c8aeb9029c8","tarball":"http://registry-npm.ywwl.com/markdown-it-emoji/download/markdown-it-emoji-2.0.2.tgz","fileCount":18,"unpackedSize":200920,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCH91m7MdsMeIWwkbSglt4UEng5eR2ZKydtkIpA4dZllQIgXEaZiS4Zrv+YFDPi+u4u+cXVH/mh5P8rq4t1prAVQIg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiYt9EACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpvVg//VJFjZT2n2apuz3vRZ2ZqmpkEbF8q7iSDFyrWIgnxR016dxg7\r\nP+a58rZHv1QJBF1eLxTCNsGIvOBajNwGQYaNBAUVNz+Vvry/mqlbNb88Mben\r\nF9KMikDjMp39oy1SriUPsOf6pmvI3S/UpMa4bkt8GYk/OG8RDT0xdrzGBGpS\r\n/wJlrUNWqnNrnPy/5LCNrcVox7YjUJNogegCazNYspJIpjHSJgbG6f6pOF4i\r\nypY4zLVaJE7wew4eSaX+fa86dT2BDe9oW+KMeKZiM+d2oa1jbYxT/nMvIszZ\r\nDt+k539foXegUGvNx7oqKwIvO5T5PclzP5D5lPMPGOSCzaDD++PXQUbR+fRO\r\nG3FHmqczYAMUNK0Q2iKr93qoE8Oj2xs175YWrEBmJLylHVUUsBV2dMsAW6Ku\r\nkRB8UI9YRmIzeyiob8VUTndXOG04n3RYglyEOQ632GiTLsEVe9pw+8EnO7Ku\r\n9OqJxxcwxfOEcZgJTvpq7UYfrCb+zX0UfJsGQHNqVR/B9p/WxLSNsOLSUcgC\r\nc5N2JGhWZx9H9U4H+1ohRoweQiXwWSjShrLmKfQRSCmKmY7ZLADBJ3wlIGYo\r\n4/ZnMLQmj73Xc614tpSMbKb65NQ0rePFkhR2ZEUvviLGY7dNbzAgwLmfGvzH\r\n2xeH4IqCO7Ugv+ggoTgErI35rr5P1PFbn4s=\r\n=XuuO\r\n-----END PGP SIGNATURE-----\r\n","size":61123,"noattachment":false,"key":"/markdown-it-emoji/-/markdown-it-emoji-2.0.2.tgz"},"_npmUser":{"name":"vitaly","email":"vitaly@rcdesign.ru"},"directories":{},"maintainers":[{"name":"vitaly","email":"vitaly@rcdesign.ru"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/markdown-it-emoji_2.0.2_1650646852353_0.8478496293328459"},"_hasShrinkwrap":false,"readme":"# markdown-it-emoji\n\n[![CI](https://github.com/markdown-it/markdown-it-emoji/actions/workflows/ci.yml/badge.svg)](https://github.com/markdown-it/markdown-it-emoji/actions/workflows/ci.yml)\n[![NPM version](https://img.shields.io/npm/v/markdown-it-emoji.svg?style=flat)](https://www.npmjs.org/package/markdown-it-emoji)\n[![Coverage Status](https://coveralls.io/repos/markdown-it/markdown-it-emoji/badge.svg?branch=master&service=github)](https://coveralls.io/github/markdown-it/markdown-it-emoji?branch=master)\n\n> Plugin for [markdown-it](https://github.com/markdown-it/markdown-it) markdown parser, adding emoji & emoticon syntax support. Also supports emoticons [shortcuts](https://github.com/markdown-it/markdown-it-emoji/blob/master/lib/data/shortcuts.js) like `:)`, `:-(`, and others.\n\n__NOTE. v3 changed exports, see below.__\n\n\n## Install\n\n```bash\nnpm install i markdown-it-emoji\n```\n\n## Use\n\n### init\n\n```js\n//\n// { full, light, bare } configs available.\n//\n//  full:  includes all available emojis support\n//  light: includes small subset of most useable emojis\n//  bare:  no defaults\n//\n// Also CJS & UMD builds available in `dist/` folder of published package,\n// if your env not supports ESM modules use.\n//\nimport { full as emoji } from 'markdown-it-emoji'\nimport markdownit from 'markdown-it'\n\nconst md = markdownit().use(emoji/* , options */);\n```\n\nOptions are not mandatory:\n\n- __defs__ (Object) - rewrite available emoji definitions\n  - example: `{ name1: char1, name2: char2, ... }`\n- __enabled__ (Array) - disable all emojis except whitelisted\n- __shortcuts__ (Object) - rewrite default shortcuts\n  - example: `{ \"smile\": [ \":)\", \":-)\" ], \"laughing\": \":D\" }`\n\n_Differences in browser._ If you load the script directly into the page without\nusing a package system, the module will add itself globally with the name `markdownitEmoji`.\n\n### change output\n\nBy default, emojis are rendered as appropriate unicode chars. But you can change\nthe renderer function as you wish.\n\nRender as span blocks (for example, to use a custom iconic font):\n\n```js\n// ...\n// initialize\n\nmd.renderer.rules.emoji = function(token, idx) {\n  return '<span class=\"emoji emoji_' + token[idx].markup + '\"></span>';\n};\n```\n\nOr use [twemoji](https://github.com/twitter/twemoji):\n\n```js\n// ...\n// initialize\n\nimport twemoji from 'twemoji'\n\nmd.renderer.rules.emoji = function(token, idx) {\n  return twemoji.parse(token[idx].content);\n};\n```\n\n__NB 1__. Read [twemoji docs](https://github.com/twitter/twemoji#string-parsing)!\nIn case you need more options to change image size & type.\n\n__NB 2__. When using twemoji you can make image height match the line height with this\nstyle:\n\n```css\n.emoji {\n  height: 1.2em;\n}\n```\n\n### In your markdown file\n\n```md\nHello from mars :satellite:\n```\n\nbecomes\n\n```\nHello from mars 📡\n```\n","publish_time":1650646852516,"_cnpm_publish_time":1650646852516,"dist-tags":{"latest":"3.1.0"}}