How to configure it with lazy vim?
Hi,
I have the following snippet in my init.lua file, the plugin is loaded but the scrollbar isn't visible at all.
{
"petertriho/nvim-scrollbar",
config = function ()
require("scrollbar").setup()
end,
dependencies = {
"lewis6991/gitsigns.nvim",
"kevinhwang91/nvim-hlslens"
}
}
Need your help for the review or suggestions. New to this configuration.
I use this config
return {
'petertriho/nvim-scrollbar',
dependencies = {
'lewis6991/gitsigns.nvim',
'kevinhwang91/nvim-hlslens',
},
opts = {},
}
and the scrollbar shows and I even get the marks warnings and errors. I can't see git changes or search results though.
I just enabled search an git with this config, hope it helps (not a vim wiz or anything, just trying to get a decent nvim config, so there's probably better ways to do this)
return {
'petertriho/nvim-scrollbar',
dependencies = {
'lewis6991/gitsigns.nvim',
'kevinhwang91/nvim-hlslens',
},
opts = {},
config = function()
require('scrollbar').setup()
require('gitsigns').setup()
require('hlslens').setup {
build_position_cb = function(plist, _, _, _)
require('scrollbar.handlers.search').handler.show(plist.start_pos)
end,
}
require('scrollbar.handlers.gitsigns').setup()
require('scrollbar.handlers.search').setup()
end,
}
@adilJamshad Can you try explicitly setting the scrollbar handle color to something? Your theme might be causing it to be hidden
require("scrollbar").setup({
handle = {
text = " ",
color = "#ffffff",
},
}
@tjcocucci
return {
'petertriho/nvim-scrollbar',
dependencies = {
'lewis6991/gitsigns.nvim',
'kevinhwang91/nvim-hlslens',
},
opts = {
handlers = {
gitsigns = true,
search = true,
},
},
}
This should be all that's required. The handler setup functions works as well, they are there for lazy loading purposes