Async update for php docs
This commit is contained in:
parent
7abdf5a770
commit
c1147e912b
1 changed files with 10 additions and 0 deletions
|
@ -6,10 +6,20 @@
|
|||
(add-hook! php-mode 'flycheck-mode)
|
||||
(setq php-template-compatibility nil
|
||||
php-extras-eldoc-functions-file (concat narf-temp-dir "php-extras-eldoc-functions"))
|
||||
|
||||
:config
|
||||
(require 'php-extras)
|
||||
(define-company-backend! php-mode '(php-extras-company))
|
||||
|
||||
(unless (file-exists-p (concat php-extras-eldoc-functions-file ".el"))
|
||||
(async-start `(lambda ()
|
||||
,(async-inject-variables "\\`\\(load-path\\|php-extras-eldoc-functions-file\\)$")
|
||||
(require 'php-extras-gen-eldoc)
|
||||
(php-extras-generate-eldoc-1 t))
|
||||
(lambda (_)
|
||||
(load (concat php-extras-eldoc-functions-file ".el"))
|
||||
(message "PHP eldoc updated!"))))
|
||||
|
||||
;; TODO Tie into emr
|
||||
(require 'php-refactor-mode)
|
||||
(add-hook! php-mode '(turn-on-eldoc-mode emr-initialize php-refactor-mode)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue