fix(vscode): simplify marketplace README rendering#8073
Closed
kilo-code-bot[bot] wants to merge 1 commit intomainfrom
Closed
fix(vscode): simplify marketplace README rendering#8073kilo-code-bot[bot] wants to merge 1 commit intomainfrom
kilo-code-bot[bot] wants to merge 1 commit intomainfrom
Conversation
Remove embedded images and HTML tables from the extension README so the VS Code marketplace view stays lightweight and avoids known markdown rendering slow paths.
|
|
||
| function images(src: string) { | ||
| const html = [...src.matchAll(/<img\b[^>]*src=["']([^"']+)["'][^>]*>/gi)].map((m) => m[1]) | ||
| const md = [...src.matchAll(/!\[[^\]]*\]\(([^)]+)\)/g)].map((m) => m[1]) |
Contributor
Author
There was a problem hiding this comment.
WARNING: Regression test misses reference-style Markdown images
images() only matches inline  syntax. A future README change could reintroduce an embedded image with reference-style Markdown like ![alt][ref] plus [ref]: https://..., and this test would still pass even though the Marketplace would still render the image.
Contributor
Author
Code Review SummaryStatus: 1 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
Other Observations (not in diff)Issues found in unchanged code that cannot receive inline comments: None. Files Reviewed (2 files)
Reviewed by gpt-5.4-20260305 · 157,744 tokens |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
<table>markup intopackages/kilo-vscode/README.mdProblem
Opening this extension's README from the VS Code Marketplace view can drive CPU usage extremely high. The old README was unusually expensive for the markdown renderer because it combined three patterns that are all known to stress VS Code's markdown/extension-details rendering path:
Many remote image fetches on initial render
raster.shields.io, 8 contributor avatars fromavatars.githubusercontent.com, and 1 YouTube thumbnail fromimg.youtube.com.HTML-heavy markdown
<table>with inline-styled contributor avatars.A code path with prior VS Code perf issues
microsoft/vscode#138409- extension README loading time regressionmicrosoft/vscode#197868- high CPU load frommarkdown-language-featuresmicrosoft/vscode#165055- markdown preview becomes unusable with many picturesWhy this README can trigger 400% CPU
The most plausible mechanism is not that any single image is huge, but that the README creates a bursty render workload:
That fits the reported symptom: simply opening the Marketplace README is enough to spike multiple cores, even though the extension code itself is not executing a heavy feature.
Fix
This PR takes the safe fix available from the extension side: make the Marketplace README cheap to render.
This does not require a VS Code platform change and directly reduces renderer work, network fan-out, and layout churn.
Why this fix is the right tradeoff
Guardrail
packages/kilo-vscode/tests/unit/marketplace-readme.test.tsnow verifies that the Marketplace README:<table>markupThis makes the performance regression less likely to come back during future README edits.
Validation
bun test tests/unit/marketplace-readme.test.tsRisk
Low.