diff --git a/lua/config/lazy.lua b/lua/config/lazy.lua index d4cc69d..05d8d5e 100644 --- a/lua/config/lazy.lua +++ b/lua/config/lazy.lua @@ -20,6 +20,7 @@ require("lazy").setup({ { import = "plugins" }, { import = "plugins.langs.python" }, { import = "plugins.langs.go" }, + { import = "plugins.langs.xml_json_html" }, }, defaults = { -- By default, only LazyVim plugins will be lazy-loaded. Your custom plugins will load during startup. diff --git a/lua/plugins/conform.lua b/lua/plugins/conform.lua index 45be7ae..dc1609a 100644 --- a/lua/plugins/conform.lua +++ b/lua/plugins/conform.lua @@ -1,14 +1,14 @@ return { - "stevearc/conform.nvim", - opts = { - formatters_by_ft = { - -- python = { "ruff" }, - python = { "black" }, - javascript = { "biome" }, - go = {'goimports', 'gofumpt'} - }, - }, - dependencies = { - "mason.nvim", - }, + "stevearc/conform.nvim", + opts = { + formatters_by_ft = { + python = { "black" }, + javascript = { "biome" }, + go = { "goimports", "gofumpt" }, + xml = { "lemminx" }, + }, + }, + dependencies = { + "mason.nvim", + }, } diff --git a/lua/plugins/langs/xml_json_html/nvim-lspconfig.lua b/lua/plugins/langs/xml_json_html/nvim-lspconfig.lua new file mode 100644 index 0000000..d51ca94 --- /dev/null +++ b/lua/plugins/langs/xml_json_html/nvim-lspconfig.lua @@ -0,0 +1,22 @@ +return { + "neovim/nvim-lspconfig", + opts = { + servers = { + lemminx = { + init_options = { + settings = { + xml = { + format = { + enabled = true, + splitAttributes = false, + }, + validation = { + noGrammar = "ignore", -- This is correct + }, + } + } + } + } + } + } +}