-
-
Notifications
You must be signed in to change notification settings - Fork 934
Closed
Description
Is your feature related or already mentioned on the wishlist?
Mentioned briefly in the second point of : #2892 (comment)
First of all, thanks to all the contributors of lsp-mode.
Feature request:
Option to include/prefix lsp:completion-item-detail
text to lsp:completion-item-documentation?
.
It currently clutters the completion popup, especially with typescript language server.
I have added an advice to merge the detail and the documentation, which solves the problem for me, but would be good to have this as a configuration if possible.
Please refer to before and after screenshots below:
Before
(setq lsp-completion-show-detail t)
(company-posframe-mode 1)
After
(setq lsp-completion-show-detail nil)
(company-posframe-mode 1)
(defun improved-completion-quick-help (orig item &rest args)
(let ((doc (apply orig item args))
(detail
(-some->> item
(get-text-property 0 'lsp-completion-item)
(lsp:completion-item-detail?)))
)
(concat "\n" detail "\n\n" doc)))
(advice-add 'lsp-completion--get-documentation :around #'improved-completion-quick-help)
mpereirayorisilo
Metadata
Metadata
Assignees
Labels
No labels