Create utils.lua file and add ToggleBackground command
This commit is contained in:
11
config/nvim/lua/utils.lua
Normal file
11
config/nvim/lua/utils.lua
Normal file
@@ -0,0 +1,11 @@
|
||||
local M = {}
|
||||
|
||||
M.toggleBackground = function ()
|
||||
if vim.opt.background:get() == "dark" then
|
||||
vim.opt.background = "light"
|
||||
else
|
||||
vim.opt.background = "dark"
|
||||
end
|
||||
end
|
||||
|
||||
return M
|
||||
Reference in New Issue
Block a user