diff --git a/home-manager/modules/emacs/config.org b/home-manager/modules/emacs/config.org index a4a8664..0afcdd9 100644 --- a/home-manager/modules/emacs/config.org +++ b/home-manager/modules/emacs/config.org @@ -1107,6 +1107,7 @@ Prefer local packages from =node_modules= to global ones #+begin_src emacs-lisp (use-package web-mode + :mode "\\.svelte\\'" :after eglot :config (setq web-mode-markup-indent-offset 2 @@ -1119,7 +1120,8 @@ Prefer local packages from =node_modules= to global ones (add-to-list 'web-mode-engines-alist '(("elixir" . "\\.html.heex\\'") ("jinja2" . "\\.jinja2\\'") - ("python" . "\\.pt\\'"))) + ("python" . "\\.pt\\'") + ("svelte" . "\\.svelte\\'"))) :hook ((html-mode css-mode web-mode) . eglot-ensure)) #+end_src @@ -1617,6 +1619,20 @@ Register =nushell= LSP with eglot (use-package lua-mode) #+end_src +*** Svelte + +#+begin_src emacs-lisp + (use-package svelte-mode) +#+end_src + +Use =svelteserver= as LSP + +#+begin_src emacs-lisp + (with-eval-after-load 'eglot + (add-to-list 'eglot-server-programs + '(svelte-mode . ("svelteserver" "--stdio")))) +#+end_src + * Org ** Main org setup