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

Avoid duplicate markdown sanitization #210524

Closed
wants to merge 2 commits into from
Closed

Avoid duplicate markdown sanitization #210524

wants to merge 2 commits into from

Conversation

DonJayamanne
Copy link
Contributor

For #210528

@@ -186,7 +186,7 @@ suite('MarkdownRenderer', () => {
</thead>
<tbody><tr>
<td><span class="codicon codicon-zap"></span></td>
<td><a data-href="#link" href="" title="#link" draggable="false"><span class="codicon codicon-zap"></span>-link</a></td>
<td><a draggable="false" title="#link" href="" data-href="#link"><span class="codicon codicon-zap"></span>-link</a></td>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only changed the order of the attributes, else the HTML is identical

@DonJayamanne DonJayamanne assigned mjbvz and unassigned DonJayamanne Apr 17, 2024
@DonJayamanne DonJayamanne marked this pull request as ready for review April 17, 2024 18:40
@vscodenpa vscodenpa added this to the April 2024 milestone Apr 17, 2024
@mjbvz
Copy link
Collaborator

mjbvz commented Apr 18, 2024

Also would like to get a repo. In my testing of the linked issue, the call to sanitize takes under 1ms. Even if we don't call sanitize twice, it sounds like we'd still be taking 150ms or so which isn't acceptable

@DonJayamanne
Copy link
Contributor Author

n my testing of the linked issue, the call to sanitize takes under 1ms. Even if we don't call sanitize twice, it sounds like we'd still be taking 150ms or so which isn't acceptable

Sometimes I have seen this taking 300ms when working on notebooks, we use markdown parser to build outlines and that ends up parsing markdown which results in 300ms sometimes.
So, this is definitely happening in other places too, but not 100% of the time.
The issue does definitely repro for me, please let me know if CPU profiles will help and what else information you need.

@microsoft microsoft locked and limited conversation to collaborators Jun 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants