emoji-tones

Regular expression for capturing all skin-tone variations of an emoji

喜欢而已 提交于 2019-12-11 09:56:09
问题 I'm trying to use a regex to capture tweets containing the substring 👏 at least twice, so I'm using an unsophisticated ^.+ 👏 .+ 👏 .+$ . However this doesn't match strings which instead contain, for example, 👏🏼 . Is there a smart way I can capture an emoji with any or none skin-tone variation, without just putting each one in a row (like [👏👏🏻👏🏼👏🏽👏🏾👏🏿] )? 回答1: Thanks to comments above, I've found that emojis I've encountered on twitter are unicode, and skin-tone variations are combining