Files
dotfiles/modules/applications/vim/plugins/editor/conform.nix
T
2026-08-03 15:10:03 +09:00

28 lines
1.1 KiB
Nix

_: {
programs.nixvim.plugins."conform-nvim" = {
enable = true;
settings = {
formatters_by_ft = {
javascript.__raw = ''{ "biome", "prettierd", "prettier", stop_after_first = true }'';
javascriptreact.__raw = ''{ "biome", "prettierd", "prettier", stop_after_first = true }'';
typescript.__raw = ''{ "biome", "prettierd", "prettier", stop_after_first = true }'';
typescriptreact.__raw = ''{ "biome", "prettierd", "prettier", stop_after_first = true }'';
json.__raw = ''{ "biome", "prettierd", "prettier", stop_after_first = true }'';
yaml.__raw = ''{ "prettierd", "prettier", stop_after_first = true }'';
markdown.__raw = ''{ "prettierd", "prettier", stop_after_first = true }'';
lua = [ "stylua" ];
nix.__raw = ''{ "nix_fmt", "alejandra", stop_after_first = true }'';
sh = [ "shfmt" ];
};
formatters.nix_fmt = {
command = "nixfmt";
};
format_on_save.__raw = ''
function(_)
return { timeout_ms = 1000, lsp_format = "fallback" }
end
'';
};
};
}