typescript, java: use new :append-hooks and :call-hooks
This is necessary as we use hack-local-variables-hook to setup the backends, at this time it is too late to setup hooks, we need to call the function right away.
This commit is contained in:
parent
883f57ee74
commit
0877f2f92a
|
@ -191,11 +191,11 @@
|
|||
(spacemacs|add-company-backends
|
||||
:backends company-emacs-eclim
|
||||
:modes eclim-mode
|
||||
:hooks nil)
|
||||
;; call manualy generated functions by the macro
|
||||
(spacemacs//init-company-eclim-mode)
|
||||
(set (make-variable-buffer-local 'company-idle-delay) 0.5)
|
||||
(set (make-variable-buffer-local 'company-minimum-prefix-length) 1)
|
||||
:variables
|
||||
company-idle-delay 0.5
|
||||
company-minimum-prefix-length 1
|
||||
:append-hooks nil
|
||||
:call-hooks t)
|
||||
(company-mode))
|
||||
|
||||
(defun spacemacs//java-setup-eclim-flycheck ()
|
||||
|
|
|
@ -80,8 +80,9 @@
|
|||
(spacemacs|add-company-backends
|
||||
:backends company-lsp
|
||||
:modes typescript-mode typescript-tsx-mode
|
||||
:variables
|
||||
company-minimum-prefix-length 2)
|
||||
:variables company-minimum-prefix-length 2
|
||||
:append-hooks nil
|
||||
:call-hooks t)
|
||||
(company-mode))
|
||||
(message "`lsp' layer is not installed, please add `lsp' layer to your dofile.")))
|
||||
|
||||
|
|
Loading…
Reference in New Issue