From 6f522c08939cfbe5f2993a093dd8302aa438fb57 Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Tue, 6 Sep 2022 10:21:10 +1000 Subject: showing docs in hcel-ids mode, switch to buffer --- lisp/hcel-utils.el | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lisp/hcel-utils.el') diff --git a/lisp/hcel-utils.el b/lisp/hcel-utils.el index c7b6755..9db5d81 100644 --- a/lisp/hcel-utils.el +++ b/lisp/hcel-utils.el @@ -140,4 +140,11 @@ Example of an idSrcSpan: (alist-get 'exprType (alist-get 'info expr))))) (cons expression type))) +(defun hcel-render-html (html) + (when html + (with-temp-buffer + (insert html) + (shr-render-region (point-min) (point-max)) + (buffer-string)))) + (provide 'hcel-utils) -- cgit v1.2.3