Skip to content

Commit a2b3010

Browse files
committed
language/svelte: remove broken format option
1 parent 1869f46 commit a2b3010

File tree

1 file changed

+1
-40
lines changed

1 file changed

+1
-40
lines changed

modules/plugins/languages/svelte.nix

Lines changed: 1 addition & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
inherit (lib.options) mkEnableOption mkOption;
99
inherit (lib.modules) mkIf mkMerge;
1010
inherit (lib.meta) getExe;
11-
inherit (lib.types) enum package;
11+
inherit (lib.types) enum;
1212
inherit (lib.nvim.types) mkGrammarOption diagnostics singleOrListOf;
1313
inherit (lib.nvim.attrsets) mapListToAttrs;
1414
inherit (lib.generators) mkLuaInline;
@@ -53,19 +53,6 @@
5353
};
5454
};
5555

56-
# TODO: specify packages
57-
defaultFormat = "prettier";
58-
formats = {
59-
prettier = {
60-
package = pkgs.prettier;
61-
};
62-
63-
biome = {
64-
package = pkgs.biome;
65-
};
66-
};
67-
68-
# TODO: specify packages
6956
defaultDiagnosticsProvider = ["eslint_d"];
7057
diagnosticsProviders = {
7158
eslint_d = let
@@ -105,22 +92,6 @@ in {
10592
};
10693
};
10794

108-
format = {
109-
enable = mkEnableOption "Svelte formatting" // {default = config.vim.languages.enableFormat;};
110-
111-
type = mkOption {
112-
type = enum (attrNames formats);
113-
default = defaultFormat;
114-
description = "Svelte formatter to use";
115-
};
116-
117-
package = mkOption {
118-
type = package;
119-
default = formats.${cfg.format.type}.package;
120-
description = "Svelte formatter package";
121-
};
122-
};
123-
12495
extraDiagnostics = {
12596
enable = mkEnableOption "extra Svelte diagnostics" // {default = config.vim.languages.enableExtraDiagnostics;};
12697

@@ -147,16 +118,6 @@ in {
147118
cfg.lsp.servers;
148119
})
149120

150-
(mkIf cfg.format.enable {
151-
vim.formatter.conform-nvim = {
152-
enable = true;
153-
setupOpts.formatters_by_ft.svelte = [cfg.format.type];
154-
setupOpts.formatters.${cfg.format.type} = {
155-
command = getExe cfg.format.package;
156-
};
157-
};
158-
})
159-
160121
(mkIf cfg.extraDiagnostics.enable {
161122
vim.diagnostics.nvim-lint = {
162123
enable = true;

0 commit comments

Comments
 (0)