22 lines
598 B
Lua
22 lines
598 B
Lua
vim.pack.add({ "https://github.com/stevearc/conform.nvim" })
|
|
|
|
local Conform = require("conform")
|
|
|
|
Conform.setup({
|
|
notify_on_error = false,
|
|
format_on_save = {
|
|
-- These options will be passed to conform.format()
|
|
timeout_ms = 500,
|
|
lsp_format = "fallback",
|
|
},
|
|
|
|
formatters_by_ft = {
|
|
lua = { "stylua" },
|
|
javascript = { "biome" },
|
|
javascriptreact = { "biome" },
|
|
typescript = { "biome" },
|
|
typescriptreact = { "biome" },
|
|
-- You can use 'stop_after_first' to run the first available formatter from the list
|
|
-- javascript = { "prettierd", "prettier", stop_after_first = true },
|
|
},
|
|
})
|