This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-02-02
Channels
- # announcements (13)
- # architecture (18)
- # babashka (90)
- # beginners (80)
- # calva (35)
- # chlorine-clover (29)
- # cider (24)
- # clj-kondo (4)
- # cljfx (3)
- # clojure (60)
- # clojure-australia (2)
- # clojure-europe (60)
- # clojure-france (2)
- # clojure-germany (3)
- # clojure-italy (4)
- # clojure-nl (84)
- # clojure-norway (7)
- # clojure-uk (53)
- # clojurescript (54)
- # clojureverse-ops (1)
- # community-development (6)
- # conjure (1)
- # contributions-welcome (1)
- # cursive (12)
- # datomic (1)
- # fulcro (16)
- # garden (61)
- # girouette (1)
- # graalvm (14)
- # hugsql (1)
- # instaparse (5)
- # jobs-discuss (11)
- # keechma (1)
- # lambdaisland (3)
- # off-topic (20)
- # pathom (1)
- # re-frame (3)
- # reitit (2)
- # releases (1)
- # remote-jobs (2)
- # reveal (11)
- # shadow-cljs (58)
- # spacemacs (5)
- # sql (3)
- # startup-in-a-month (1)
- # vim (2)
@noprompt hi š
I would like to contribute for the https://github.com/noprompt/garden/issues/171, but first I wanted to ask a few questions.
Does garden have any sort of visitor, a spec about the garden data format or anything like that ?
It would be handy for writing any kind of garden-rewriting function.
@vincent.cantin No, but Iām sure itās possible to fit something on top of it. The design is pretty bad; it was one of my first āseriousā Clojure projects. You probably noticed, a second version in the works ā the aleph
branch ā but it too needs work.
I did not know about the aleph branch. I made a library which is creating garden data (https://github.com/green-coder/girouette), thatās the reason I am interested in improving Garden.
I would be happy to explain in detail where the aleph branch needs to be in terms of release quality.
Maybe I could write a data model for the Garden format using Minimallist and use it to visit the nodes.
I am equally desesperate for help with my projects, I totally understand you š
I think what would really help would be to have a proper āparseā phase to get the data into a format which can be more easily manipulated.
This is what I was doing on the aleph
branch: a protocol for parsing stuff into AST nodes (maps) and separate phases for manipulating /compiling those.
Two things need to happen on that branch: 1. the parser needs to be written in vanilla clojure, no spec, no conform, etc. 2. finish up the docs (but this is less important than the first)
By āvanilla clojureā, what do you mean? what is your goal exactly?
(garden.parse/parse ["h1" {:font-weight "bold"}])
;; =>
[:rule [:block [:selector "h1"] ,,,]]]
Something like this or whatever (probably maps not hiccup though)Your goal is not to have dependencies ?
FWIW, I think the idea you mentioned on the ticket is similar to what happens on aleph
branch IIRC
I will take a look at the aleph
branch in the next couple of days.
In the near future, do you plan to maintain both branches master
and aleph
or do you plan to replace master
when you can?
I think this could be done with a zipper by finding the media query node, replacing it with itās contents, then replacing that path along the tree with the media query e.g.
[,,, [,,, (at-media {,,,} <stuff>)]]
;; =>
(at-media {,,,} [,,, [,,, <stuff>]])
I think that you should write it somewhere in the README.md, because many contributors may not know that and will work only on master.
Communicate on the direction of the project so that people can be side by side with you.
Small detail: the git branch is spelled alef
, not aleph
At some point in Girouette, I will want to group CSS rules which belong in the same media queries. Itās at that point that having all the media queries at the root will be useful.
For now, I use a work around in my code to construct my data with the media query at the root, but itās a little hacky.
TBH, and Iāve mentioned this in the #meander channel as well, Iām very bad a writing documentation/sending emails. OTOH Iām usually very good at replying here in this format.
The reason is that between the things I enumerated earlier which occupy my time and mind is a head in the clouds.
I also struggle with time, having a full time job not even related to Clojure and a family to take care of. I got your point.
I might have time next week to look at alph and see what I can do on it.
You +1 me, I have 2
But I promise you, if you want to work on the project I will give you my full support
@noprompt I will cut a first release for Girouette first, then see how to improve Garden right after.
I would say itās log
if you can teach them to take care of each other.
If you want to add something to what is on master you could do it before here: https://github.com/noprompt/garden/blob/master/src/garden/compiler.cljc#L765