mirror of
https://github.com/NotAShelf/nvf.git
synced 2024-11-23 13:50:44 +00:00
27 lines
544 B
Nix
27 lines
544 B
Nix
|
{
|
||
|
config,
|
||
|
lib,
|
||
|
...
|
||
|
}: let
|
||
|
inherit (lib) mkIf nvim;
|
||
|
inherit (builtins) toString;
|
||
|
|
||
|
cfg = config.vim.lsp.nvim-docs-view;
|
||
|
in {
|
||
|
config = mkIf cfg.enable {
|
||
|
vim = {
|
||
|
lsp.enable = true;
|
||
|
startPlugins = ["nvim-docs-view"];
|
||
|
|
||
|
luaConfigRC.nvim-docs-view = nvim.dag.entryAnywhere ''
|
||
|
require("docs-view").setup {
|
||
|
position = "${cfg.position}",
|
||
|
width = ${toString cfg.width},
|
||
|
height = ${toString cfg.height},
|
||
|
update_mode = "${cfg.updateMode}",
|
||
|
}
|
||
|
'';
|
||
|
};
|
||
|
};
|
||
|
}
|