lang/{web,javascript}: remove +web-bower-mode; refactor react, phaser & angular detection
This commit is contained in:
parent
dd8c3d0d1e
commit
53b9e92fd7
4 changed files with 19 additions and 46 deletions
|
@ -14,6 +14,18 @@ ignore the cache."
|
|||
(json-read-file package-file)))
|
||||
(puthash project-root json +javascript-npm-conf))))))
|
||||
|
||||
;;;###autoload
|
||||
(defun +javascript-npm-dep-p (packages &optional project-root refresh-p)
|
||||
(when-let (data (and (bound-and-true-p +javascript-npm-mode)
|
||||
(+javascript-npm-conf)))
|
||||
(let ((deps (append (cdr (assq 'dependencies data))
|
||||
(cdr (assq 'devDependencies data)))))
|
||||
(funcall (if (eq (car packages) 'and)
|
||||
'cl-every
|
||||
'cl-some)
|
||||
(lambda (pkg) (assq pkg deps))
|
||||
(if (listp packages) packages (list packages))))))
|
||||
|
||||
;;;###autoload
|
||||
(defun +javascript/repl ()
|
||||
"Open a Javascript REPL. Meaning either `skewer-repl', if any of the
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue