dd and yy only affect a single line instead of the entire folded
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.2k
- Forks
- 1.5k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 6
Description
issue Description
Describe the bug
When a code block is folded, performing a dd (delete) or yy (yank) operation only affects the first line of the fold instead of the entire collapsed block. This breaks the expected behavior where a folded range should be treated as a single entity for editing commands.
To Reproduce
Create a large JavaScript function or object.
Fold the block (e.g., using zc or the editor's fold icon).
Position the cursor on the folded line.
Press dd.
Expected behavior
The entire folded block should be deleted.
Actual behavior
Only the top-level line (e.g., function foo() {) is deleted, leaving the rest of the block's content orphaned and unfolded.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with a folded JavaScript function or object, using zc or the fold icon, then press dd and yy on the folded line. Trace the fold-aware handling of these editing commands and confirm that the entire collapsed block is treated as one range without leaving its contents orphaned.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100