Skip to content

Commit 385bf15

Browse files
warbaconzenvignesh
authored andcommitted
perf: load tokyonight.nvim in the intended way (nvim-lua#1360)
Fixes nvim-lua#1357
1 parent 14167b7 commit 385bf15

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

init.lua

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -897,14 +897,18 @@ require('lazy').setup({
897897
-- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
898898
'folke/tokyonight.nvim',
899899
priority = 1000, -- Make sure to load this before all the other start plugins.
900-
init = function()
900+
config = function()
901+
---@diagnostic disable-next-line: missing-fields
902+
require('tokyonight').setup {
903+
styles = {
904+
comments = { italic = false }, -- Disable italics in comments
905+
},
906+
}
907+
901908
-- Load the colorscheme here.
902909
-- Like many other themes, this one has different styles, and you could load
903910
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
904911
vim.cmd.colorscheme 'tokyonight-night'
905-
906-
-- You can configure highlights by doing something like:
907-
vim.cmd.hi 'Comment gui=none'
908912
end,
909913
},
910914

0 commit comments

Comments
 (0)