Skip to content

Commit 2034811

Browse files
committed
Enable inlay hints for the supporting servers
1 parent 2377390 commit 2034811

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

init.lua

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -518,6 +518,14 @@ require('lazy').setup({
518518
callback = vim.lsp.buf.clear_references,
519519
})
520520
end
521+
522+
-- The following autocommand is used to enable inlay hints in your
523+
-- code, if the language server you are using supports them
524+
--
525+
-- This may be unwanted, since they displace some of your code
526+
if client and client.server_capabilities.inlayHintProvider and vim.lsp.inlay_hint then
527+
vim.lsp.inlay_hint.enable(event.buf, true)
528+
end
521529
end,
522530
})
523531

0 commit comments

Comments
 (0)