Refactoring & 設定でTwemojiを使うかどうか切り替えられるように

This commit is contained in:
syuilo
2018-11-05 19:20:35 +09:00
parent 54e9147782
commit 65961bc15b
13 changed files with 95 additions and 58 deletions

View File

@@ -2,5 +2,5 @@ import parse from '../../../mfm/parse';
export default function(text: string) {
if (!text) return [];
return parse(text).filter(t => t.type === 'emoji').map(t => (t as any).emoji);
return parse(text).filter(t => t.type === 'emoji' && t.name).map(t => (t as any).name);
}