remarkjs / react-markdown

Markdown component for React

Home Page:https://remarkjs.github.io/react-markdown/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for inapp links

daniil00d opened this issue · comments

Initial checklist

Problem

When inputting a link formatted as [hello]({any_app}://something) or <{any_app}://something>, a link node with an empty href is created.

Solution

I'd like the library to support this case: we input a link to an application (installed on the current device), and upon clicking said link, the application is opened. An example being: click me

Alternatives

One potential solution could be to give the user more control over the transformation of links obtained from the text. This could be achieved, for example, by extending the transformLinkUri prop, where it would be possible to access the protocol, domain, pathname, query, etc.

Welcome @daniil00d! 👋

They are supported, but disabled by default as they are insecure.
You can set your own URL transform in the options https://github.com/remarkjs/react-markdown#options
See #774 for some examples

Hi! This was closed. Team: If this was fixed, please add phase/solved. Otherwise, please add one of the no/* labels.

Hi! Thanks for taking the time to contribute!

Because we treat issues as our backlog, we close duplicates to focus our work and not have to touch the same chunk of code for the same reason multiple times. This is also why we may mark something as duplicate that isn’t an exact duplicate but is closely related.

Thanks,
— bb

Hi team! It seems this post is a duplicate, but hasn’t been marked as such. Please post a comment w/ Duplicate of #123(no final .) to do so. See GH docs for more info.

Thanks,
— bb

Duplicate of #774