Slowly replace use-package with with-eval-after-load

This commit is contained in:
Maciej 2024-10-23 11:06:19 +03:00
parent c7b0c1c6c2
commit 1fe168ccc6
Signed by: maciej
GPG key ID: 41D62D42D3B0D765
10 changed files with 360 additions and 377 deletions

View file

@ -3,22 +3,23 @@
;;; Highlight misspelled words
;;; Code:
(use-package ispell
:ensure nil
:config (setq ispell-program-name "aspell")
(setq ispell-extra-args
'("--run-together" "--run-together-limit=5" "--run-together-min=2"))
:hook ((prog-mode text-mode markdown-mode) . flyspell-mode))
(add-hook 'flyspell-mode-hook (lambda ()
(unbind-key "C-," flyspell-mode-map)
(unbind-key "C-." flyspell-mode-map)
(unbind-key "C-;" flyspell-mode-map)
(unbind-key "C-c $" flyspell-mode-map)
(unbind-key "C-M-i" flyspell-mode-map)))
(use-package ispell :ensure nil)
(use-package flyspell-correct :ensure t :after flyspell :defer t)
(use-package flyspell-correct-ivy :ensure t :after flyspell-correct :defer t)
(with-eval-after-load 'ispell
(setq
ispell-program-name "aspell"
ispell-extra-args '("--run-together" "--run-together-limit=5" "--run-together-min=2"))
(add-hook 'prog-mode-hook #'flyspell-mode)
(add-hook 'text-mode-hook #'flyspell-mode)
(add-hook 'markdown-mode-hook #'flyspell-mode)
(add-hook 'flyspell-mode-hook (lambda ()
(unbind-key "C-," flyspell-mode-map)
(unbind-key "C-." flyspell-mode-map)
(unbind-key "C-;" flyspell-mode-map)
(unbind-key "C-c $" flyspell-mode-map)
(unbind-key "C-M-i" flyspell-mode-map))))
(provide 'icejam-ispell)
;;; icejam-ispell.el ends here