add nvchad-config

This commit is contained in:
2024-03-07 15:46:59 +07:00
parent c804fb8d2b
commit 2af9ff9194
9 changed files with 295 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
--type conform.options
local options = {
lsp_fallback = true,
formatters_by_ft = {
lua = { "stylua" },
javascript = { "prettier" },
css = { "prettier" },
html = { "prettier" },
sh = { "shfmt" },
},
-- adding same formatter for multiple filetypes can look too much work for some
-- instead of the above code you could just use a loop! the config is just a table after all!
-- format_on_save = {
-- -- These options will be passed to conform.format()
-- timeout_ms = 500,
-- lsp_fallback = true,
-- },
}
require("conform").setup(options)