This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-11-18
Channels
- # beginners (84)
- # boot (21)
- # cider (12)
- # cljs-dev (13)
- # cljsrn (3)
- # clojure (169)
- # clojure-dusseldorf (2)
- # clojure-gamedev (6)
- # clojure-germany (1)
- # clojure-russia (15)
- # clojure-serbia (4)
- # clojure-spec (16)
- # clojure-uk (4)
- # clojurescript (51)
- # core-async (1)
- # datomic (23)
- # emacs (16)
- # figwheel (1)
- # fulcro (60)
- # hoplon (8)
- # lein-figwheel (3)
- # leiningen (1)
- # luminus (4)
- # lumo (43)
- # off-topic (4)
- # re-frame (17)
- # rum (37)
- # shadow-cljs (21)
- # test-check (13)
- # vim (14)
2.0.0-SNAPSHOT updated on clojars. History refined. There is a feature/2.0 branch of todomvc that works with the new version and can show a couple of the features of the new history support (compressed transacts, tx tracking)
@wilkerlucio So, the factory “fix” (apply) does break things a bit. It changes how children appear
When making defui components that expect children, they used to always appear as a vector, whereas not if there is just one, for example, then children will no longer be a vector…just an element. This will break existing code for 2.0. Not sure which way to go…breakage of existing code, or elimination of an annoying react warning
I think it might be fixable by changing how the prim/children
function works to this:
(defn children
"Returns the component's children."
[component]
(let [cs #?(:clj (:children component)
:cljs (.. component -props -children))]
(if (coll? cs) cs [cs])))
Thoughts?that way existing users that are pulling children always get a collection (as before), but the factory change can stay in place for when React pulls them
Using Fulcro 2.0. The :started-callback
function has app
as a parameter. But an assert on (prim/reconciler? (:reconciler app))
is failing.
function (config,state,meta,extmap,hash){ this.config = config; this.state = state; this.meta = meta; this.extmap = extmap; this.hash = hash; this.cljs$lang$protocol_mask$partition0$ = 2229700362; this.cljs$lang$protocol_mask$partition1$ = 139264; }
the code looks right to me, and most of that hasn’t changed…just my call to the construction of the Reconciler now uses mine, but it implements the protocol
if you accidentally end up with both, things might compile and give you strange errors because some of your namespaces might have gotten missed or something
I guess none of the internal asserts are pulling reconciler from the app. It is in the app for your external purposes…so it could be broken I guess. I just don’t see how
My renaming stuff is naive…it assumes you followed the pattern of requires [om.next :as om]
My misconception before was that namespaces will change with Fulcro 2, so it is more than a fork, which might keep the same namespaces??
No compile errors. I think fulcrologic/fulcro-spec and fulcrologic/fulcro-datomic also ought to be upgraded to 2.0 - they might be pulling in om??
It is not a fork, per se, no. It is a completely new thing that keeps the same function names, but does create new namespaces for them. This is because they are technically different things.
yeah, if you copy/paste that (assuming OSX or Linux) it should get you most of the way there
might also work in something like cygwin for winders….is that even a thing, or did they make something new…so long since I’ve touched windows…like since version 7 or something
curious if you use perl for that kind of stream editing, or something else. sed
is ok but I really prefer perl regex support 😉
I used to use sed
for things. Been a very long time since needed to do shell scripting. My professional existence has been very much Windows for last 7 years.
`Call to #'fulcro.cli … ailure :instrument↵" Call to #'fulcro.client.impl.data-fetch/place-load-markers did not conform to spec:↵ In: [1 0 :fulcro.client.primitives/ident] val: nil fails spec: :fulcro.client.primitives/ident at: [:args :items :fulcro.client.primitives/ident] predicate: ident?↵`
Next is a stack trace of many Uncaught TypeError: Cannot read property 'call' of undefined
, all for factory calls, starting with my TopRouter then going down to DropdownItem (bootstrap3 line 517) and finally ShadowDOM (elements line 82).
Problem happens when doing the swap!
that mounts the Root
component: No protocol method ISwap.-swap! defined for type undefined
.
Hey @cjmurphy So, instrument should not be turned on just yet I think, if you’re turning it on (for spec)