diff options
-rw-r--r-- | custom/jao-custom-eww.el | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/custom/jao-custom-eww.el b/custom/jao-custom-eww.el index efa0828..0e77feb 100644 --- a/custom/jao-custom-eww.el +++ b/custom/jao-custom-eww.el @@ -163,6 +163,16 @@ ("C-c C-w" . jao-eww-close) ("M-i" . eww-toggle-images)))) +;;; auto-readable +(defvar jao-eww-auto-readable-urls + (regexp-opt '("guardian.co.uk" "theguardian.com" "github.com"))) + +(defun jao-eww-autoread () + (when (string-match-p jao-eww-auto-readable-urls (or (eww-current-url))) + (eww-readable))) + +(add-hook 'eww-after-render-hook #'jao-eww-autoread) + ;;; fixes for shr image rendering (require 'shr) |