mfm_parser 1.0.1 copy "mfm_parser: ^1.0.1" to clipboard
mfm_parser: ^1.0.1 copied to clipboard

mfm (Markup Language For Misskey) parser for dart.

mfm_parser #

MFM (Misskey Flavor Markdown) parser implementation for dart.

This package is not renderer of the mfm.

Features #

This package was ported from typescript project of misskey-dev/mfm.js and depended on twitter/twemoji-parser too.

Getting started #

dart pub add mfm_parser

if you use flutter,

flutter pub add mfm_parser

Usage #

you can use MfmParser().parse() or MfmParser().parseSimple(). simpleParser is only supported to the text and emoji. you can used it for such as user name.

final text = r"""
<center>$[x2 **What's @ai**]</center>
@ai is official mascot character of the Misskey.
you can see more information from <https://xn--931a.moe/>
""";

final list = const MfmParser().parse(text);

print(list);

TODO #

These feature will be supported in the future.

  • This package is not compatible with 'toString()' and many api from the official mfm.js.
  • This package is not support math-inline and math-block.
2
likes
0
pub points
59%
popularity

Publisher

verified publishershiosyakeyakini.info

mfm (Markup Language For Misskey) parser for dart.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

collection

More

Packages that depend on mfm_parser