Fork me on GitHub

I am trying to install datomic in my local and getting below error, Can anyone help me please


Is there a beginner friendly way to create graalvm programs? I tried but there is something wrong with the clojure class path or something. I followed the readme example and needed to add clojure do deps.edn to make it compile but the resulting program throws Caused by: Could not locate clojure/core__init.class,


There is a channel #graalvm where you can ask for help. And here is a nice collection of useful resources -

👍 2
Thanh Nguyen13:09:59

Hi guys. I am learning reagent and trying to write a simple CRUD app. There is a weird behavior that I am being confused about, however. If my code is like this, the atomic immediately becomes null after every of the input change:

(defonce selected-user-map (reagent.core/atom {:name "" :surname ""}))
     {:value (:name @selected-user-map)
      :on-change (fn [event]
                   (let [new-name (-> event .-target .-value)]
                     (swap! selected-user-map assoc :name new-name)))}]
If I change the swap! to reset!, stuff works as expected:
(reset! selected-user (merge @selected-user-map {:name new-name}))
Is there any special reason on the behavior? I thought that swap! and reset! should have yielded similar result, or I misunderstood something? Thanks in advance.

Thanh Nguyen13:09:27

This is a GIF for clarification. It records the behavior when I use swap! • Select an user • Try modifying the selected user with the input • The selected user become null

Vlad Kryvokoniev13:09:30

Hi, I have problem adjusted to shadow-cljs env variables As the "not clearly" says I can read a variable via #shadow/env "TWITCH_AUTHORIZATION_TOKEN" but instead i get an error No reader function for tag shadow/env. my version of shadow-cljs is "2.15.2" here is my shadow-cljs.edn:


 [[reagent "1.1.0"]
  [cljs-ajax "0.8.4"]]

 :dev-http {8080 "public"}
  {:target :browser
   :modules {:main {:init-fn app/start}}
   :closure-defines {events.async/TWITCH_AUTHORIZATION_TOKEN #shadow/env "TWITCH_AUTHORIZATION_TOKEN"}}}} 
also my .env:
so my question is how to read a env variable then?


That file looks like a weird amalgamation of a project.clj, a deps.edn, and the shadow-cljs.edn file described in those docs


And that is exactly the error I would expect in you tried to use the shadow tag readers in a deps.edn file


Ah, I just missed the other keys in the docs


how do you write hiccup for @keyframes tag for css animation? Muchos Gracias!

dgb2307:09:49 has support for media queries and keyframes


I think with hiccup you would have to create a style tag, or include a CSS file.


HI I had a look at garden... but I still can't generate the keywords definition.

(println (css [(keyword "@keyframes") {:from {:background {:color "red"}}
                        :to {:background {:color "blue"}}}
Generates ->
@keyframes {
  from-background-color: red;
  to-background-color: blue;
Which looks good... but I want to generate
@keyframes example {
  from-background-color: red;
  to-background-color: blue;
However when I run the following
(println (css [(keyword "@keyframes") "example" {:from {:background {:color "red"}}
                        :to {:background {:color "blue"}}}]))
I get
@keyframes, example {
  from-background-color: red;
  to-background-color: blue;


@U01EFUL1A8M Many thanks for your help. But I can't figure out how to still use it! Please can you show me 1 example? I'll be forever grateful!


@U06MDAPTP Sorry to bother you. Is there a proper tutorial for using garden somewhere?


Does this help?

(ns user
  (:require [garden.stylesheet :refer [at-keyframes]]
            [garden.core :refer [css]]))

(css (at-keyframes :slidein
                   [:from {:transform "translateX(0%)"}]
                   [:to {:transform "translateX(100%)"}]))


(edited syntax error)


ahh... I see what the problem is... the name of the keyframes also needs to be a keyword... instead of a string!! Thank you very much @U01EFUL1A8M!! I would have never figured this out! Many thanks!


No problem! All I have done is: fire up a REPL, look at the source code of CSS garden and searched it and played around a bit. All good and fun.

👍 2
🙌 2