Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Parser adapter and renderer adapter #69

Closed
IlyaGulya opened this issue Sep 27, 2018 · 1 comment
Closed

Feature request: Parser adapter and renderer adapter #69

IlyaGulya opened this issue Sep 27, 2018 · 1 comment

Comments

@IlyaGulya
Copy link

Hello!
Looks like currently library supports only commonmark-java for parsing Markdown.
Here is a lot more powerful library named flexmark-java.
It supports more markdown dialects and extensions.

How about adding ability to make some kind of adapter interface for parser to be able to use libraries other than commonmark-java?

I think to make it possible we need:

  • Make parser adapter
  • Make renderer adapter
@noties
Copy link
Owner

noties commented Sep 27, 2018

Hello @IlyaGulya !

I'm aware of flemark-java. It's definitely more feature-full than commonmark-java (flexmark-java is also a fork of commonmark-java). But I do not think that creating 2 adapters will help to achieve multiple parsers support. Of cause, the idea is great, but I do not see a way currently. It's more like switch to flexmark-java than add support to it (due to various differences between the two).

There are also things to consider:

  • commonmark-java has better performance
  • with Plugin system #65 each plugin will have to define implementation for each parser
  • there is an open issue in commonmark-java repository that can make things a tad better (extensible inline parser) after it is resolved (although it's open for some time..)

But anyway if you see how this can be done with minimal damage, you are absolutely welcome to share it, it would be a great feature 100% 🙌

@noties noties closed this as completed Mar 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants