Repository navigation
Skip Markdown structure scans without link delimiters - #35055
Merged
Merged
Conversation
This was referenced Oct 28, 2026
OrcaWin
force-pushed
the
OrcaWin/editor-link-free-admission
branch
from
October 28, 2026 23:17
91075c6 to
55ef4ff
Compare
OrcaWin
marked this pull request as ready for review
October 29, 2026 00:08
Contributor
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 7 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
[Low impact] The PR appears safe to merge. Summary
Reviews (2) · Last reviewed commit: "perf(editor): skip Markdown link structu..." · Reviewed by Greptile |
OrcaWin
force-pushed
the
OrcaWin/editor-link-free-admission
branch
from
October 29, 2026 00:27
55ef4ff to
0f18d39
Compare
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.
Problem
getMarkdownDocLinkDecorationRangesruns when a Markdown source pane mounts and on every debounced content change. Each run builds the fenced-code ranges and walks every line, even when the document has no[[...]]wiki links, which is true of most Markdown files.Fix
Search for the delimiters before doing any structural work. If there is no
[[, or no]]after the first[[, no link can exist, so return[]before the fence scan and the line walk. The first]]search now starts atnextOpen + 2instead of 0. This finds the same closing delimiter the loop's re-search would have found, so output does not change.Test
pnpm test src/renderer/src/components/editor/monaco-markdown-doc-link-decorations: the existing output oracle, generated-syntax corpus, fence, CRLF and inline-code tests pass unchanged.pnpm check:changedpasses.