Settings to control suggestions.

This commit is contained in:
Dalius Dobravolskas 2020-10-25 21:58:22 +02:00
parent 17c0c3c731
commit 81d16823a7
No known key found for this signature in database
GPG key ID: ADD0F648032E3224
2 changed files with 10 additions and 0 deletions

View file

@ -159,6 +159,7 @@ function! ale#lsp_linter#HandleLSPResponse(conn_id, response) abort
call s:HandleTSServerDiagnostics(a:response, 'syntax')
elseif get(a:response, 'type', '') is# 'event'
\&& get(a:response, 'event', '') is# 'suggestionDiag'
\&& get(g:, 'ale_lsp_suggestions', '1') == 1
call s:HandleTSServerDiagnostics(a:response, 'suggestion')
endif
endfunction

View file

@ -1677,6 +1677,15 @@ g:ale_lsp_show_message_severity *g:ale_lsp_show_message_severity*
`'disabled'` - Doesn't display any information at all.
g:ale_lsp_suggestions *g:ale_lsp_suggestions*
Type: |Number|
Default: 1
This variable defines if suggestions must be collected from LSP or tsserver
and shown.
g:ale_lsp_root *g:ale_lsp_root*
*b:ale_lsp_root*