-
-
Notifications
You must be signed in to change notification settings - Fork 886
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
Opening link in a new tab #65
Comments
You can use a custom renderer: function LinkRenderer(props) {
return <a href={props.href} target="_blank">{props.children}</a>
}
<ReactMarkdown
source="Click [here](https://espen.codes/) to visit external site"
renderers={{link: LinkRenderer}}
/> |
@rexxars |
it works here with the capital |
Can you please consider re-open this ticket in order to implementing support for opening a link in a new tab: Is this feature make sense? |
For anyone else that ends up here via google search (like I did) and didn't notice this in the docs, you can now use the <ReactMarkdown linkTarget="_blank" children={...} /> See the docs for more info. |
Does React Markdown automatically add |
This answer is pretty outdated, and should no longer be used as a reference. I'm locking this thread as outdated. |
Is it possible to add
target="blank"
to Markdown links?For example I wish to have the following URL open in a new browser tab when I left click:
[link to website](http://www.website.com)
Cheers
The text was updated successfully, but these errors were encountered: