[MFM] Improve hashtag detection
This commit is contained in:
@ -186,6 +186,14 @@ describe('Text', () => {
|
||||
], tokens);
|
||||
});
|
||||
|
||||
it('with text (zenkaku)', () => {
|
||||
const tokens = analyze('こんにちは #世界');
|
||||
assert.deepEqual([
|
||||
text('こんにちは '),
|
||||
node('hashtag', { hashtag: '世界' })
|
||||
], tokens);
|
||||
});
|
||||
|
||||
it('ignore comma and period', () => {
|
||||
const tokens = analyze('Foo #bar, baz #piyo.');
|
||||
assert.deepEqual([
|
||||
|
Reference in New Issue
Block a user