Skip to content

Commit 13051e7

Browse files
warbaconAlessandro201
authored andcommitted
perf: load tokyonight.nvim in the intended way (nvim-lua#1360)
Fixes nvim-lua#1357
1 parent bcdb68b commit 13051e7

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
@@ -1040,14 +1040,18 @@ require('lazy').setup({
10401040
-- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
10411041
'folke/tokyonight.nvim',
10421042
priority = 1000, -- Make sure to load this before all the other start plugins.
1043-
init = function()
1043+
config = function()
1044+
---@diagnostic disable-next-line: missing-fields
1045+
require('tokyonight').setup {
1046+
styles = {
1047+
comments = { italic = false }, -- Disable italics in comments
1048+
},
1049+
}
1050+
10441051
-- Load the colorscheme here.
10451052
-- Like many other themes, this one has different styles, and you could load
10461053
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
10471054
vim.cmd.colorscheme 'tokyonight-night'
1048-
1049-
-- You can configure highlights by doing something like:
1050-
vim.cmd.hi 'Comment gui=none'
10511055
end,
10521056
},
10531057

0 commit comments

Comments
 (0)