Files
neovim/lua/format.lua
2026-03-19 16:14:24 -05:00

25 lines
518 B
Lua

plugin({
"stevearc/conform.nvim",
event = { "BufWritePre" },
cmd = { "ConformInfo" },
opts = {
formatters_by_ft = {
lua = { "stylua" },
elixir = { "mix" },
javascript = { "prettier" },
css = { "prettier" },
html = { "prettier" },
html = { "prettier" },
typescript = { "deno_fmt" },
heex = { "mix" },
nix = { "nixfmt" },
json = { "prettier" },
},
format_on_save = {
-- These options will be passed to conform.format()
timeout_ms = 2000,
lsp_fallback = true,
},
},
})