Fork me on GitHub
#re-frame
<
2021-12-24
>
Noah Bogart01:12:48

Given that the new recommended way to write reg-event-fx handlers is to only return :db and :fx keys in the returned map, and that :fx should now be a vector of map entries/2-value vectors, should the example code in the tutorial/documentation be rewritten in that style? Stuff like this: http://day8.github.io/re-frame/dominoes-30k/#domino-3-effect-handling

Noah Bogart01:12:04

I’m willing to open a PR if this is desired

p-himik09:12:27

I think that would be best. Day8 guys are quite welcoming with documentation fixes, and just a message here will definitely get lost. And if not a PR, then at least an issue should be made, if there isn't one already.

Noah Bogart14:12:08

Cool, I’ll do it then! I can at least get the ball rolling in the transition

👍 1
Noah Bogart16:12:16

here’s my go at it. i’m not well-versed with writing documentation, so any input would be helpful: https://github.com/day8/re-frame/pull/749

Noah Bogart01:12:59

Tho now that I'm looking, the infographics would also have to be updated, which I know nothing about

Benjamin15:12:09

[:failed-to-compare "16.9.0" "16.9.0" #error {
 :cause "Cannot invoke \"Object.getClass()\" because \"target\" is null"
 :via
 [{:type java.lang.NullPointerException
   :message "Cannot invoke \"Object.getClass()\" because \"target\" is null"
   :at [clojure.lang.Reflector invokeInstanceMethod "Reflector.java" 97]}]
 :trace
 [[clojure.lang.Reflector invokeInstanceMethod "Reflector.java" 97]
  [shadow.cljs.devtools.server.npm_deps$make_engine invokeStatic "npm_deps.clj" 39]
  [shadow.cljs.devtools.server.npm_deps$make_engine invoke "npm_deps.clj" 32]
  [shadow.cljs.devtools.server.npm_deps$fn__17833$fn__17834 invoke "npm_deps.clj" 46]
  [clojure.lang.Delay deref "Delay.java" 42]
  [clojure.core$deref invokeStatic "core.clj" 2320]
  [clojure.core$deref invoke "core.clj" 2306]
  [shadow.cljs.devtools.server.npm_deps$fn__17833$fn__17836 invoke "npm_deps.clj" 52]
  [shadow.cljs.devtools.server.npm_deps$resolve_conflict invokeStatic "npm_deps.clj" 83]
  [shadow.cljs.devtools.server.npm_deps$resolve_conflict invoke "npm_deps.clj" 78]
do you recognize this error? I created the re-frame template with clj -A:new re-frame-template

p-himik15:12:45

Sounds more like a #shadow-cljs issue rather than a re-frame one. Perhaps the template uses old shadow-cljs version? Can't really reproduce it because I don't know what your :new alias is doing.

Bobbi Towers21:12:07

I've been getting this as well in a shadow/re-frame project. Everything still works as far as I can tell so I've just been ignoring it.

Benjamin08:12:18

https://github.com/omnyway-labs/re-frame-template/tree/HEAD it uses this as a template. I'll try putting stuff on newer versions

Noah Bogart15:12:01

Did you run npm install?

Noah Bogart16:12:16

here’s my go at it. i’m not well-versed with writing documentation, so any input would be helpful: https://github.com/day8/re-frame/pull/749