0.0.1 • Published 1 year ago
strip-emoji v0.0.1
strip-emoji
(forked from emoji-strip)
Use emoji-regex
to Strip emoji from a string in Node.js and browsers.
Examples
import emojiStrip from "strip-emoji";
const cleaned = emojiStrip("unicorn 🦄 rainbow 🌈"); // "unicorn rainbow "API
stripEmoji(string)
Returns a copy of string with any emoji characters removed.
Supported emoji
The emojiStrip function uses
the emoji-regex package
behind the scenes.
It can remove any of the emoji supported by that package.
Currently, it supports all emoji up to Unicode Version 10 except for emoji sequences.
Install
For Node.js
Install with npm:
npm install --save strip-emojiRequire it in your program:
var emojiStrip = require('strip-emoji')For browsers
Download one of the versions of strip-emoji.js:
- strip-emoji.js (uncompressed)
- strip-emoji.min.js (minified)
Link it in your HTML:
<script src="strip-emoji.min.js"></script>License
ISC
0.0.1
1 year ago