autoload/lsp/options.vim | 6 +++--- doc/lsp.txt | 4 +++- plugin/lsp.vim | 4 ++-- diff --git a/autoload/lsp/options.vim b/autoload/lsp/options.vim index fd8cbaa491baabbcb7e41b060403a077c3f5dbd9..f1605f7252629d96656e1ec9f2e3071df4195f99 100644 --- a/autoload/lsp/options.vim +++ b/autoload/lsp/options.vim @@ -49,9 +49,9 @@ lspOptions[key] = opts[key] endfor enddef -# get LSP option value per user provided key -export def OptionsGet(key: string): any - return lspOptions[key] +# get LSP options +export def OptionsGet(): dict + return lspOptions enddef # vim: tabstop=8 shiftwidth=2 softtabstop=2 diff --git a/doc/lsp.txt b/doc/lsp.txt index 923edbbae37e1d4402c6fa753125e49c8fa6849f..b7d6e86526f0ea7ac81c06d1f7dabc96947f0112 100644 --- a/doc/lsp.txt +++ b/doc/lsp.txt @@ -285,8 +285,10 @@ < And to get or check one option value via its key you can query like following: > - echo LspOptionsGet('autoHighlightDiags') + echo LspOptionsGet()['autoHighlightDiags'] < +Or if no specific key but just LspOptionsGet() then to get all options. + ============================================================================== 5. Commands *lsp-commands* diff --git a/plugin/lsp.vim b/plugin/lsp.vim index 98fad20691e9ef049960707f274e2ad69e69f04f..163b5291dfe3f43992fc33b75a8b335bfdb195ed 100644 --- a/plugin/lsp.vim +++ b/plugin/lsp.vim @@ -14,8 +14,8 @@ def g:LspOptionsSet(opts: dict) options.OptionsSet(opts) enddef -def g:LspOptionsGet(key: string): any - return options.OptionsGet(key) +def g:LspOptionsGet(): dict + return options.OptionsGet() enddef def g:LspAddServer(serverList: list>)