Skip to content

⚡Fix the auto-scroll to the middle of the screen when switching between buffers in Neovim

License

Notifications You must be signed in to change notification settings

BranimirE/fix-auto-scroll.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

⚡ Fix Auto Scroll Neovim

fix-auto-scroll is a lua plugin for Neovim that changes the default behavior in Neovim when switching between buffers. By default in Neovim when you switch to another buffer and get back to the previous buffer the cursor's line number is preserved but that line number is positioned in the middle of the screen vertically. This plugin is based on the idea exposed in this post.

✨ Features

  • fix the default Neovim behavior that sets the current line in the middle of the screen when switching between buffers

⚡️ Requirements

  • Neovim >= 0.7.2. This number will be updated as soon it is tested in other versions

📦 Installation

Install the plugin with your preferred package manager:

{
  'BranimirE/fix-auto-scroll.nvim',
  config = true,
  event = 'VeryLazy'
}
call plug#begin()
Plug 'BranimirE/fix-auto-scroll.nvim'
call plug#end()

lua require('fix-auto-scroll').setup()

⚙️ Configuration

For now, it does not accept any configuration

About

⚡Fix the auto-scroll to the middle of the screen when switching between buffers in Neovim

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages