Workaround "cursorMove" command bug in VSCode API until its fixed
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.2k
- Forks
- 1.5k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 6
Description
Is your feature request related to a problem? Please describe.
The L motion doesn't work correctly, but it's actually caused by a bug in VSCode API, sadly it seems like they don't plan to fix it anytime soon.
Describe the solution you'd like
We could make a workaround until they fix it. L should not scroll the viewPort, same as H and M don't.
Describe alternatives you've considered
I've tried patching it myself, it works correctly for movement (simply L), but fails at dL, cL, etc.
Additional context
The main problem is how in VSCode moving to the last visible line scrolls the viewPort so you always can see the line below. Also both Vim and NeoVim always renders full lines.
How pressing repeatedly H M L works right now:

How pressing repeatedly H M L works after my patch (almost like Vim):

How my patch fails at dL (without my patch it doesn't work correctly either):

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
Start by tracing the VSCode API cursorMove handling for the H, M, and L motions, then compare the linked patch's behavior for plain L with dL and cL. The work is done when L no longer scrolls the viewport like H and M, while operator combinations behave correctly and match the described Vim and NeoVim rendering behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100