Skip to content

Commit bcf2145

Browse files
warbaconmonk3yd
authored andcommitted
perf: load tokyonight.nvim in the intended way (nvim-lua#1360)
Fixes nvim-lua#1357
1 parent 356b757 commit bcf2145

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

init.lua

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -952,15 +952,19 @@ require('lazy').setup({
952952
--
953953
-- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
954954
'folke/tokyonight.nvim',
955-
priority = 2000, -- Make sure to load this before all the other start plugins.
956-
init = function()
955+
priority = 1000, -- Make sure to load this before all the other start plugins.
956+
config = function()
957+
---@diagnostic disable-next-line: missing-fields
958+
require('tokyonight').setup {
959+
styles = {
960+
comments = { italic = false }, -- Disable italics in comments
961+
},
962+
}
963+
957964
-- Load the colorscheme here.
958965
-- Like many other themes, this one has different styles, and you could load
959966
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
960967
vim.cmd.colorscheme 'tokyonight-night'
961-
962-
-- You can configure highlights by doing something like:
963-
vim.cmd.hi 'Comment gui=none'
964968
end,
965969
},
966970

0 commit comments

Comments
 (0)