visual-studio-codehorizontal-scrollingvertical-scrolling

Synchronise vertical/horizontal scrolling in split view


Is there a way in VS Code to synchronise vertical or horizontal scrolling in splitted view ?

Like in Notepad++ for instance :

From buttons:

Notepad++ Vertical/Horizontal sync

From View menu:

Notepad++ Vertical/Horizontal sync


Solution

  • 2024 EDIT: There is now an official editor-action named "View: Toggle Locked Scrolling Across Editors".

    To engage it, open the Command Palette (⌘⇧P(Mac)/^⇧P(Win/Linux)) and type in the action name. Select it and hit enter.

    See this official Youtube Short for a demo.

    --

    2021 Edit: While the below does still work, as per @Mr.D.Q's answer below, there does now exist a plugin Sync Scroll to accomplish this task.

    --

    From what I can find, the closest thing you can do is use the "Compare Files" feature.

    In the File-Explorer sidebar: