-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Slow startup with lualine integration #28
Comments
@alexmozaidze Hmmm, that's very odd. I can't think of an obvious reason for this either. Try creating a minimal config that includes just Modicator (and perhaps also lualine and your colorscheme). Does that give you the same behaviour? I personally lazy load it on |
I did some experimenting and found out that lualine integration was the root cause of slow startup. Toggle lualine integration on/off to see the difference in startup time. Here's a minimal vimrc with Lazy for profiling: Minimal config-- Bootstrapping Lazy package manager
local lazypath = vim.fn.stdpath "data" .. "/lazy/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
vim.fn.system {
"git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
"--branch=stable",
lazypath,
}
end
vim.opt.rtp:prepend(lazypath)
-- Setting up plugins
require "lazy".setup {
{
"nvim-lualine/lualine.nvim",
event = "UIEnter",
init = function()
vim.opt.showmode = false
end,
opts = {},
},
{
"mawkler/modicator.nvim",
event = "UIEnter",
init = function()
vim.o.cursorline = true
vim.o.number = true
vim.o.termguicolors = true
end,
opts = {
integration = {
lualine = {
-- Toggle for slow startup
enabled = false
}
}
}
},
{
"alexmozaidze/palenight.nvim",
priority = 1000,
},
}
-- Load the sexy
vim.cmd.colorscheme "palenight" |
@alexmozaidze I get 60-70 ms startup for Modicator with Lualine integration enabled, and ~10 ms with it disabled. What version of Neovim are you using? I'm currently testing on nightly v0.10.0-dev-1962+gc26dc1f77. |
But it happens on Nightly too, iirc. Sorry for late response. |
I see! Yeah I'm not sure what could be causing this for you. I'll leave this open and see if anyone else has a similar issue that can help us figure out what's going on. |
I've noticed in the Lazy profiler that Modicator takes a long time to load, somewhere around 600-900ms. When I remove Modicator, Neovim opens almost instantly. I am unsure of what's causing such a slowdown, and glancing over the codebase, couldn't think of any probable cause.
Note
In order to view the actual time it takes for the plugin to load, lazy-load it upon
UIEnter
.The text was updated successfully, but these errors were encountered: