react-markdown-preview
react-markdown-preview copied to clipboard
A tag don't work
"a Tag" works fine in react-markdown, but not in react-md-editor's preview.
Maybe I use this component.
import ReactMarkdownWithHtml from 'react-markdown/with-html';
Is there any way I can extend it?
I hope the problem is solved well, and thank you for making a nice app :)
https://github.com/uiwjs/react-md-editor/issues/56#issuecomment-717892235
@MoonSupport You can try to setting props?: ReactMarkdownProps
;
-
transformLinkUri
- function|null Function that gets called for each encountered link with a single argument - uri. The returned value is used in place of the original. The default link URI transformer acts as an XSS-filter, neutralizing things like javascript:, vbscript: and file: protocols. If you specify a custom function, this default filter won't be called, but you can access it as require('react-markdown').uriTransformer. If you want to disable the default transformer, pass null to this option. -
escapeHtml
- boolean Setting to false will cause HTML to be rendered (see notes below about proper HTML support). Be aware that setting this to false might cause security issues if the input is user-generated. Use at your own risk. (default: true). -
skipHtml
- boolean Setting to true will skip inlined and blocks of HTML (default: false).
Thank you for your answer. :)
But sorry, I don't understand your propose. 😞
First, escapeHtml
and skipHtml
should be false ( default value ) for activating a
tag
And, transformLinkUri
seems to be something like middleware used to block specific protocols.
But I can't solve my problem just by understanding above it.