Fork me on GitHub
#cider
<
2023-09-02
>
vemv20:09:53

In case you find the musing fun, today I spent most of my hack time formatting Javadoc as something that will look clear within a CIDER widget. It's a fairly wicked problem, because javadoc mixes natural text with html, so you have to parse a not-quite-html string, while preserving newlines and table alignment. I got it solved with a mixture of Jsoup on the cider-nrepl side, and https://github.com/emacs-mirror/emacs/blob/3dac48d1b73794d2379e233f11736d0279b0733c/lisp/net/shr.el on the elisp side. You can look at how unusable it was before here: https://github.com/clojure-emacs/orchard/issues/179

❤️ 4
vemv05:09:09

Some progress - Java syntax highlighting right in the autocompletion widget

👏 4
aisamu01:09:15

Thanks a lot for this!

❤️ 2
vemv11:09:04

Cheers guys, thanks for the encouragement :) I have kept working on this. I replaced Jsoup with JDK's official javadoc parser. So here you have progress (vs. screenshot in OP): • unwrapped <@U018HQ11FTK> s • Nicely formatted Throws/Returns etc

🎉 2
vemv11:09:01

If you want to help making this a reality, consider giving Enrich a spin! https://clojurians.slack.com/archives/C0617A8PQ/p1693598934327439