clay icon indicating copy to clipboard operation
clay copied to clipboard

kind/code problems

Open genmeblog opened this issue 1 year ago • 3 comments

Hi! I see two issues regarding interpretation of code blocks by clay.

First: only strings are accepted. I propose acceptation of anything (but sequence) and applying str on content. Second: only vectors are accepted for multiple code snippets, should be changed to any sequential (here).

(kind/code 1.222)
;; exception
(kind/code "1.222")
;; ok
(kind/code ["1.22" "3.33"])
;; ok
(kind/code (list "1.22" "3.33"))
;; exception

genmeblog avatar Jun 12 '24 09:06 genmeblog

@genmeblog Thanks.

I'm wondering about your str proposal. What is your use case? (And do you maybe find kind/pprint useful in such cases?)

daslu avatar Jun 12 '24 21:06 daslu

Actually there are three options for that and these options give different results. kind/pprint wraps the value into the vector.

image

genmeblog avatar Jun 13 '24 07:06 genmeblog

Ther new version 2-beta11 supports lists as you proposed. The other parts need more discussion.

daslu avatar Jun 15 '24 19:06 daslu