This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-07-13
Channels
- # bangalore-clj (1)
- # beginners (40)
- # boot (22)
- # clara (19)
- # cljs-dev (265)
- # clojure (160)
- # clojure-dev (6)
- # clojure-italy (5)
- # clojure-russia (47)
- # clojure-spec (10)
- # clojure-uk (63)
- # clojurescript (88)
- # core-async (8)
- # cursive (54)
- # datomic (48)
- # emacs (32)
- # garden (3)
- # graphql (29)
- # hoplon (54)
- # jobs (1)
- # klipse (4)
- # luminus (5)
- # lumo (21)
- # mount (5)
- # off-topic (16)
- # om (2)
- # pedestal (10)
- # play-clj (1)
- # portkey (32)
- # re-frame (21)
- # reagent (48)
- # rum (1)
- # spacemacs (4)
- # sql (3)
- # unrepl (5)
@alandipert what was that thing you wrote where you could query vectors?
Can anyone please explain what the js-arguments
is used for in here: https://github.com/hoplon/javelin/blob/master/src/javelin/core.cljs#L193?
@thedavidmeister so I have a few proposed solutions that I am working on, the first is to move your fix to a new attribute :multi-cell
which works like and
returning the last value, it takes a sequence containing an attribute and cells. The attribute is bound to each cell. I’m calling this the n(1)
binding solution. My second proposed solution is to inform elements about their -tpl index. This could enable a tpl-cell
which updates whenever the element index changes. The third option is to always call do!
whenever an element is added to the dom.
@alandipert ^^ thoughts??
@alandipert also I am receiving weird messages from javelin java.lang.String cannot be cast to java.lang.Throwable at line 27, column 1 in file app/index.cljs
the line contains cell?
which it cannot find because I was missing the namespace however this was really hard to spot.
@ejemba js-arguments
is a function for referring to the JS arguments
keyword in a function… which refers to an array-like thing containing all arguments that were passed
@alandipert figured it out - missed that it’s inside another fn
oops, cool
@flyboarder maybe you could make an issue w/ one or both proposals?
then i can look at it later and bug micha to do the same 😄
@alandipert I see there’s the Clojure Javelin issue open: https://github.com/hoplon/javelin/issues/25 with some moderate activity
haven’t seen you cljc branch and did pretty much the same thing, only used mutable variables instead of refs
based on my recent experimentation, i don’t think the api in general is a great port to clj
in cljs you can use formulas casually for side effects, but in clj i think more rigor is required
so i think you want something that runs in the same order a formula would, but can’t have dependencies
i think the watch API could be enhanced to be this thing
esp. if the watch function is run immediately, the way do-watch does it
i started to make a new clj version a few months ago but it’s on my other computer
and then i switched to using R lol
do you mean a case where a formula does a side effect and is a source for another formula?
correct
hm, I don’t immediately see it as a big problem. You can probably shoot yourself in the foot a few times with that though
yeah, it’s really not a big problem
yeah i agree there
that’s another thing about side-efffect-only-formulas (“spouts”?)
is that they could run in other threads potentially
since they don’t have dependencies, they could actually block in a transaction and the transaction would still go
altho, a user could just make formulas or watches that put things to do in a queue
i’ll push what i had a few months ago
iirc it was mostly working and was cleaner than core-clj
my thinkpad is under the couch somewhere, i just need to retrieve it
@dm3 turns out, i already pushed: https://github.com/alandipert/plumbata
i remember it had bugs. but i don't remember what they were 🙁