portal

genekim 2023-10-30T20:39:14.273539Z

@djblue What a fantastic talk you gave at London Clojurians! I loved all the tips you gave — congrats on all the successes and progress! Not urgent, but strange: I loved all the new portal.viewers that you’ve introduced — I attempted to replicate this example, but found that bin, text, and others weren’t in version 0.48.0. i.e., the portal.viewers file doesn’t match https://github.com/djblue/portal/blob/master/src/portal/viewer.cljc. I’m guessing that file didn’t get bundled into the latest release? (In my jar file, according to IntelliJ/Cursive, the portal.viewer.cljc file is 95 lines long? The one on GitHub is 161 lines. This is super strange Is my jar file corrupted?) Purely FYI

genekim 2023-10-30T20:40:06.972729Z

Purely for your amusement — before purging my .m2 cache, I was delighted to see all these versions of Portal I’ve used over the years. All the way back to 0.12.0!

genekim 2023-10-30T20:41:01.402899Z

(I’m trying not to even contemplate that my portal.viewer.cljc file is not from 0.48.0 — that would mean somehow IntelliJ is mixing up files from different versions, which would be… confusing… and bad…)

djblue 2023-10-30T20:57:28.409339Z

Hi @genekim, I think the most recent version hasn't been released yet, sorry. I was intending on doing a release before my talk but got busy. The next version should be out shortly.

djblue 2023-10-30T20:57:37.605429Z

Thanks for all the kind word ❤️

seancorfield 2023-10-30T20:58:16.185899Z

@genekim I just exploded 0.48.0 and portal/viewer.cljc is 94 line with these functions in it:

> fgrep defn portal/viewer.cljc
(defn default
(defn for [value opts]
(defn ex
(defn log
(defn http
(defn test-report
(defn color
(defn duration-ns
(defn duration-ms
(defn pprint
(defn vega-lite
(defn vega
(defn table
(defn tree
(defn pr-str
(defn hiccup
(defn date-time
(defn diff
(defn prepl

seancorfield 2023-10-30T20:59:02.020689Z

(so you're not crazy and nor is IntelliJ 🙂 )

genekim 2023-10-30T20:59:05.890539Z

Wonderful!!! I’m so relieved — the idea of having to resolve some sort of misconfiguring in IntelliJ was… daunting. 😂 Killer presentation! I am ridiculously pleased with myself that I got this viewer defined — display as table any sequence of maps. 🎉

(def defaults
  {
   #(and (sequential? %)
         (-> % first map?))
   pv/table
   ;string? pv/text
   ;bytes? pv/bin
   ,})
(added to your example you gave in your presentation!)

genekim 2023-10-30T20:59:17.234749Z

@seancorfield I’m so relieved! Thank you!

genekim 2023-10-30T20:59:43.263479Z

@djblue Here’s the slide you presented that made me go, “Hey, I can build one of those! 🙂

djblue 2023-10-30T21:13:59.874879Z

I just started the release https://github.com/djblue/portal/actions/runs/6698796578 0.49.0 should have what you are looking for.

djblue 2023-10-30T21:16:28.992089Z

https://github.com/djblue/portal/blob/master/doc/guides/default-viewer.md is the doc version of the guide 👌

genekim 2023-10-30T21:17:26.800779Z

Brilliant — thank you, @djblue. Didn’t mean to cause you any work! I’ll check this out later today!

djblue 2023-10-30T21:19:51.942869Z

No worries, I should probably release more often. I can always release more stuff later 😂

❤️ 2
🎉 1