[feature-request] Vscode extension : narrowing to region

I work with long files (~5k Lines of Code), with nested modules.

But I have problems navigating through such long files. Although, It compensates for not having to do so much prop drilling and boiler plate. Anyways, it would be handy if there would be a way… a way to hyper focus on a part of the file!

Could the rescript vscode extension do what emacs calls narrowing-to-region?

This Focus extension is a start on the right direction, (sigh), but it is missing several features.

The ideal extension would help when editing very long files:

  • Select a module of function
  • run a command of narrowing using the command palette.
  • the extension opens the module in it’s own editor tab
  • all the changes done in the editor tab sync immediately with the filie
  • rescript extension has all the context as if it was working directly on the real file.

You can search by symbols: Code Navigation in Visual Studio Code

This feature can help: Visual Studio Code July 2022

good idea about the sticky scroll

I also toggled on the find on selection by default

Purely from a VSCode extension point of view, this definitively sounds doable.

1 Like