VSCodeVim / VSCodeVim/Vim

j,k move in the normal mode change the vs code bulit in go back and go forward behavior

Open
#4,462 2 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

kind/bug
Dominant language
TypeScript
Stars
15.2k
Forks
1.5k
Avg merge
3d 18h
Merged PRs (30d)
6

Description

Describe the bug
j,k move in the normal mode is recorded in the vs code bulit in go back and go forward action

To Reproduce

  1. go to the function definition by pressing F12
  2. press j several times
  3. use vs code built in go back (not the vim Ctrl-o) to jump back to the calling position

Expected behavior
the cursor jump back to the function calling location

Actual behavior
the cursor jump to the previous line.

when I disable vim extention, and go to next line using the down arrow key several times after jump to the function definition position, I can use the vs code built in go back to correctly go to the calling location.
I don't use the Ctrl-o, because It didn't work as expected for me either, but personally I prefer the vs code built in go back and go forward

Environment

  • Extension (VsCodeVim) version: 1.12.4
  • VSCode version: 1.41.1
  • OS: MacOS

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue in VS Code using the reported normal-mode j and k commands, F12, and the built-in Go Back action; compare it with moving using the down arrow. Trace the extension's normal-mode movement handling and its interaction with VS Code navigation history. Done means j and k no longer alter Go Back/Go Forward behavior, while the reported navigation still works.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.