-
Notifications
You must be signed in to change notification settings - Fork 17
fix: Open external links in a new tab #120
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
Conversation
cca8f4a to
a227602
Compare
a227602 to
0b3e7b0
Compare
|
Have you tested that this works? I can confirm the |
Oh shoot, yeah I saw the |
Now a two step process: * Markdown renderer adds `data-external-link` to external links * DOMPurify adds `target="_blank" rel="noopener noreferrer"` to links with that attribute Otherwise sanitization strips out the target attribute.
|
@cpsievert okay, now it works! 😃 |
Makes it easier to stop propagation if you want to prevent the dialog from showing
Fixes #11