Fork me on GitHub
#fulcro
<
2018-03-27
>
Josh Horwitz00:03:55

I'm working through the dev guide, yet when I connect to the nrepl and try to execute (require '[user :refer [start-figwheel]]) I am getting a file not found exception, is there something that I am missing?

tony.kay01:03:36

@joshua.d.horwitz hm…something seems amiss

tony.kay01:03:19

the directions assume figwheel is the default, which it isn’t anymore

tony.kay01:03:29

I need to update the guide

tony.kay01:03:18

That’s not so good. That’s actually a big change to the docs I totally missed. Seems I should probably revert the template to figwheel for now

tony.kay01:03:22

I’ve release an update to the template on clojars. If you regenerate your template according to the instructions, it should work now. I’ll leave figwheel the default until I have time to rework all of the docs.

tony.kay01:03:42

thanks for reporting it. that was a big oversight on my part

bbss03:03:47

@tony.kay I was expecting there would be a way to merge into the normalized db like it seems to here: http://book.fulcrologic.com/#_adding_sub_form_elements :append [:thing/by-id id :attribute/list] My app state thus-far is there because of a load which works well (three levels deep of entities get their data), but after my prim/app-state is tree-shaped. I would expect to transact/merge into a normalized db. Which is why I asked if it is expected to be not normalized after a load.

tony.kay03:03:12

So, normalization is a function of the query. It should be normalized if you use a proper load and query

tony.kay03:03:45

mutations have to normalize the data they add

tony.kay03:03:09

integrate-ident! does not normalize things…it expects them to already be normalized

tony.kay03:03:25

merge-component! is one way to use a component to supply a query for a merge

tony.kay03:03:54

within a mutation, use prim/merge-component

tony.kay03:03:13

the ! version would be used for, say, a websockets push

bbss03:03:56

Okay, so I guess my load didn't go as it should, since the app-state after is not normalized.

tony.kay03:03:08

what is your load?

tony.kay03:03:21

and do your components have properly joined queries with idents?

tony.kay03:03:41

and have you watched any of the YouTube series? 🙂

bbss03:03:22

I have read the dev guide a lot. Watched a bit of the youtube series, maybe I'll study it more.

tony.kay03:03:35

just making sure you knew about them 🙂

bbss03:03:18

My load:

(load app ::model/processes Root
                                         {:target [:root/processes]
                                          :marker false})
Server query-root:
(defquery-root ::model/processes
  (value [env params]
         (def env env)
         (:root/processes (prim/db->tree (:query env)
                                         @server-db
                                         @server-db))))

tony.kay03:03:01

oof…Root?

tony.kay03:03:26

not what you want 🙂

tony.kay03:03:38

what kind of thing are ::model/processes

bbss03:03:41

clojure
(spec/def ::id int?)

(spec/def ::port (spec/and int?
                           pos?))

(spec/def ::observations (spec/every #?(:clj :SC2APIProtocol.sc2api/Observation
                                       :cljs any?)))

(spec/def ::from (spec/and int?
                           #(>= % 0)))

(spec/def ::till (spec/and int
                           #(>= % 0)))

(spec/def ::run
  (spec/keys :req [::id ::from ::till ::observations]))

(spec/def ::runs (spec/every ::run))

(spec/def ::process
  (spec/keys :req [::id ::port ::runs]))

(spec/def ::processes (spec/every ::process))

tony.kay03:03:59

yeah, the other code is what I wanted, not the spec 🙂

bbss03:03:11

Okay got it. Thanks so much!

bbss03:03:55

(defsc Root [this {:keys [:ui/react-key
                          :root/processes]}]
  {:query [:ui/react-key
           {:root/processes (prim/get-query Process)}]
   :initial-state {:root/processes []}}
  (dom/div #js {:key react-key
                :style #js {"margin" 10
                            "marginLeft" 65}}
           (map #(ui-process %) processes)))

tony.kay03:03:03

you want Process

tony.kay03:03:26

the rest looks reasonable

tony.kay03:03:34

don’t need react-key anymore

bbss03:03:16

Okay, I'll give it a shot with querying for Process. I thought the whole mantra of "query goes from root" applied.

tony.kay03:03:42

So, loads load specific kinds of things. The “query composes to root” rule is a UI rule

bbss03:03:03

Okay, that makes sense. I'll figure it out!

tony.kay03:03:47

So, when you issue a load you want the query of the load to match the thing the server will return. If you’re returning a Process (or vector of Process) then you’re querying the server for Process

tony.kay03:03:08

no mind bending around the root UI query.

tony.kay03:03:15

Loads do have to load into somewhere, and they will load into the root node under the query property by default, so your :target is correct, but possibly not because you understood it correctly. Load loads the data into the root node at the “query property”, and then target will “pick it up and move it” somewhere else in the graph once it is there.

bbss03:03:27

Okay, I'll mull that over 😄 Thanks again.

tony.kay03:03:55

One of the YouTube videos is an old white-board video where I go through the loading story

tony.kay03:03:14

I’d recommend that one. It was back when it was called Untangled, so just translate the name 🙂

bbss03:03:33

I think I watched that one at the time, probably didn't get it 😅

tony.kay03:03:36

the video series also covers load in a detail

tony.kay03:03:07

don’t sweat it. You’re actually making it harder than it is…but that’s typical with anything new/different 😜

tony.kay03:03:21

too many ways things “could be”

bbss03:03:32

I hope it's even simpler than the way it "should work" in my head haha!

bbss03:03:22

And yes, many ways things could be, that was one of the problems I had with grepping om next. And the guide has given taken tons of gotchas away for me already.

tony.kay03:03:45

If “how it works” helps (I know it does for me), load combines the keyword and query of the component into a join query:

(load app :k Comp) ; means to query the server for [{:k (prim/get-query Comp)}]

tony.kay04:03:06

Oh, you studied Om Next…that’s actually a disadvantage for you 🙂

tony.kay04:03:28

because in Om Next loads DO always go from the root, and you have process-roots, and a whole bunch of network layer translation

tony.kay04:03:32

Fulcro doesn’t have any of that

tony.kay04:03:46

it’s built-in and abstracted

bbss04:03:48

Yes, it seems to require a lot less work so far. The parsing for example.

tony.kay04:03:50

you say what you want, it gets normalized and dropped into your database, then you can pepper it into the graph with post mutations or targets

bbss04:03:19

I'm gonna go and make it work! 😄

tony.kay04:03:33

I think about 7 characters of typing will do it

bbss04:03:52

:thinking_face:

bbss04:03:07

Yes! State is normalized and components got their data. Only thing besides changing the load to Process was to change the server response to change the query to [{:k (:query env)}]

levitanong06:03:14

@tony.kay when running lein test, I’m getting errors saying macro-create-element* can’t be found. I see that it’s defined as a function in .cljs. Is it possible that alpha.dom isn’t supported in the clj side?

levitanong20:03:08

Got it, thanks!

danielstockton07:03:03

I know that fulcro calls itself a library, but would people agree that it's more of a framework? I've wanted to try it several times, and always end up returning to om.next with a feeling of information overload. Despite om.next feeling slightly abandoned, it's fairly easy to understand it as a whole and know how it composes. The quick start is just great imo (https://github.com/omcljs/om/wiki/Quick-Start-(om.next)); that it doesn't use a lein template and you can get the basic idea in a few lines of code. Am I missing the trees for the fulcro forest, so to speak? It just feels like I have to read all of http://book.fulcrologic.com/ to understand everything the starter template is bootstrapping for me, and I'm yearning for a polished and maintained om-next (perhaps be more opinionated on the app-state structure) without all the distractions. Hope this doesn't read too much like a critique, because there is obviously a place for opinionated collections of libraries e.g. luminus. Just wanted to share what has prevented me from adopting fulcro (again, maybe it's just me).

danielstockton07:03:54

To put another way: it's nice to know that fulcro has thought of everything, but I kind of want a lot of it out of my face in the beginning when i'm getting started.

bbss07:03:05

@danielstockton Hmm, I've not been using fulcro for too long. But my 2 cents is that getting into fulcro has been paying off, I had tried to grok om.next, but its documentation gave me a bit of "rest of the fucking owl" feelings at times. I find that going through the admittedly big fulcro dev document has taught me to draw a much bigger part of the owl and I don't feel it's too opinionated: I recognize many problems I've run in to with web development have an obvious place to solve them cleanly with fulcro.

bbss07:03:32

I did ask and get help from the man himself a bunch of times, but really I find it a better story so far.

danielstockton07:03:30

Om.next is definitely a two circle owl (Nov 13, 2015 - Soon). I think the uneasiness that gives off is offset by the fact that I know the om.next codebase inside out and it feels like a solid base. However, fulcro feels like a very detailed owl. Hmm, do I like these ears? Can I remove this? Am I being sold an opinion here that will be hard to change later? It might be that it's a personal preference for 'start from the basics and build up' vs 'start with everything and see what I can get rid of'. Similarly, I like arch linux as my OS, because I want to start with nothing and install the packages I need, rather than have something that is catering for everyone but with a lot of bloat. It gives me a nasty 'there's something hiding in the corner' kind of feeling. At the same time, it's impossible to understand absolutely every level of a system...there's a balance somewhere.

danielstockton07:03:46

I do think the fulcro docs are a bit overwhelming and there could be a gentler introduction, where some parts of it are discovered later in the journey.

bbss07:03:16

I understand where you are coming from, I haven't found "it does too much" yet, and I think I've read most of the document. I was afraid it would be too detailed too, I already had a back-end and was initially using server-sent-events in stead of websockets. But that turned out not to work in the chrome extension I am building the cljs part in, so had to switch to websockets anyway, so fulcro choosing websockets there was no issue. Integrating fulcro on the server was not too difficult, some middleware and extend the "packer" with some transit handlers I need for sending literalbytestrings. But yeah still not used it too much so no veteran opinion here, making fast progress with my project though so that's good!

bbss07:03:53

The fulcro-inspect doesn't seem to work in my chrome extension though! But that's not a blocker.

danielstockton07:03:16

That's another good point. I also wanted to integrate with another backend, but the starter template creates both the front and backend parts in one project (i think?). There's a lot of upfront work to see how things can decompose.

danielstockton07:03:01

I would use om.next happily, but I do worry i'll be the only one maintaining it in a few months. Perhaps that's not true, people are just quietly building great things 😛

bbss07:03:56

I was already using aleph, and it that one had an adapter already (most big servers have an adapter). So plug that and some middleware with websockets.

bbss07:03:19

Took me a couple of hours to figure out.

danielstockton07:03:59

Another concern I have is that fulcro is too big to sustain itself. It's a compilation of lots of small libraries all made for this ecosystem, and that could easily fall apart. At least with om.next, I only worry about having to maintain that part.

danielstockton07:03:31

This could be totally misguided... but it's the impression I have.

bbss08:03:15

I wouldn't know about that.

danielstockton08:03:02

Anyway, I think my essay boils down to 'gentler introduction' and 'don't try to do too much'. I could easily be lured in, if it was presented more like a collection of optional, distinct libraries.

claudiu08:03:45

Personally would not put fulcro in the "framework" category. You get a lot out of the box but most it's not limiting you, or at least for me it hasn't. After all you can just use it as a state management library just mutations & query reads, build your own network. Think you can actually hook in and just write read parses like in om-next for keys also.

claudiu08:03:31

Struggled a bit to "get it"... but afterwords felt kinda stupid since explaining most of it is really simple. Was quite a bit of upfront-work for me, but really was worth it, recovered the time really fast since afterwords the project dev was just gliding along 🙂

claudiu08:03:03

And om-next. Read parsers seem very fragile, no intitial-app-state, network layer in fulcro really saves me a lot of headaches. Also if somebody will join the team I can just point them to the exact places in the docs/videos, with om-next it's really hard to onboard people

claudiu08:03:32

For my projects I really need to keep the complexity as minimal as possible, Fulcro really delivers on this, but yep "there's a bigger initial learning step". Re-frame would be a lot easier to learn, but then would have a lot extra complexity to handle in the long run. My experience with om-next is that it's hard to learn and pretty hard to maintain.

danielstockton08:03:26

"After all you can just use it as a state management library just mutations & query reads, build your own network." - I'd like to see more of this presented with much less noise. Since fulcro claims to be about 30% based on om.next, I'm not sure how it can be easier to learn. It's only easier if you're happy to ignore how certain things happen under the hood, which personally makes me a bit uncomfortable. It's nice to be able to treat some things as a black box, and concentrate on getting things done, but you want there to be clearly defined boundaries to the black box.

claudiu09:03:59

@danielstockton My experience is that you can start and be productive treating it as a blank box, but as you go through the docs/videos and fallow along on slack, it really starts to make a lot of sense, and you start learning a bit about the internals since it helps you get the most out of Fulcro.

👍 4
claudiu09:03:08

Conceptually, for me the app is has: a) generate initial app state (can use initial-app state or just pass it the atom) b) queries to get data to components (can use the default reader and fallow it's convetions or just http://book.fulcrologic.com/#_using_a_completely_custom_parser) c) mutations to modify the data (like in om-next but here you also have ptransact! for loading states etc... if you want) d) load data from the server and put it into app state (you can use df/load, put it in actions or just add it yourself to the state)

claudiu09:03:05

@danielstockton There is a bit of learning since fulcro offers quite a bit. But compared to writing/documenting/maintaining this stuff yourself ? Networking, initial-state, defsc, co-located css, ptransact! etc... Seems like quite a lot of work to get this in om-next.

danielstockton09:03:09

It's nice to have all that stuff, but it's also nice to know that you could write it yourself. Co-located css is a good example of something that could be a completely separate library: https://github.com/ladderlife/om-css I think the core could be distilled much further into the parts that actually make assumptions, and everything else discovered later, as patterns or separate libraries.

claudiu09:03:13

Think it is separate. The one from ladderlife i do not really like since it seems to only generate 1 huge css file :( fulcro css just composes and i can just have the css in the module or page.

danielstockton09:03:14

There are examples in the fulcro book that use timbre logging or internationalization, and these are in the getting started type examples. This doesn't help get across the core ideas of fulcro. It doesn't seem like there's anything preventing using fulcro-css with an om.next application, so again it seems like noise when trying to learn fulcro.

danielstockton09:03:39

It's just overhead to decompose everything and work out what is and isn't wedded to the fulcro core

danielstockton09:03:14

Anyway, i don't want to keep repeating the same thing over and over. I'm just one data point and clearly you and others were able to find your way inside to where you feel comfortable.

mitchelkuijpers09:03:54

@tony.kay @thheller I know you did some changes to the advanced compilation stuff a while ago. But we notice that prim/shared is not working anymore. Any idea if it might be related to that?

thheller09:03:19

what is prim/shared?

mitchelkuijpers09:03:41

Hmm maybe we did something wrong not sure yet

mitchelkuijpers09:03:28

I am losing shared somewhere and it's only with advanced compilation

thheller10:03:52

@mitchelkuijpers does it work when you set :js-options {:optimizations :whitespace} in your build config? if yes its a problem on the closure side of things.

thheller10:03:25

it will only affect the imported JS. the rest is still done as :advanced

mitchelkuijpers13:03:37

@thheller Thank you for the tip, with these optimizations it still loses shared, but on a dev compile shared does not dissapear

mitchelkuijpers13:03:59

New alpha dom combined with map instead of mapv makes it lose the shared state..

tony.kay15:03:18

Could you generate a failing case for me? Also, I’m still wondering if the “losing shared” is real, or an artifact of expansion that was misleading you.

tony.kay16:03:05

but what fails? You said shared, but I cannot imagine how that would be failing

mitchelkuijpers17:03:02

It did render all the items but shared was nil on all items

tony.kay19:03:11

so, just to be clear: did the new stuff fix that, too? I imagine it did, since shared is dynamically bound, so lazy eval by react after the fact won’t work

mitchelkuijpers19:03:11

Yes all is fixed

tony.kay22:03:47

OK, I’ve applied the change to localized dom as well, and re-ppushed 2.4.4-SNAPSHOT. If that checks out, I’ll cut a release.

tony.kay23:03:51

and I’ve jus tried the out with adv compile…laziness is not the problem. regular DOM was already working without any forcing with lazy seqs as far as I can tell. The problem with localized DOM is that for some reason it stops being able to detect the children correctly, and swallows children as props.

tony.kay00:03:46

So, I’m pushing up two things to try: fulcro-2.4.4-nf-SNAPSHOT does no force, but fixes a bug in localized-dom. 2.4.4-SNAPSHOT fixes the bug, but also adds forcing children. I can’t get them to behave differently, so I’d rather release the nf version, because it has less overhead. Let me know what you find.

mitchelkuijpers13:03:08

2.4.4-SNAPSHOT works perfectly with the other NF version I still get:

Uncaught TypeError: $s$jscomp$122$$.replace is not a function
    at $clojure$string$replace_all$$ (string.cljs:34)
    at $clojure$string$replace$$ (string.cljs:71)
    at $strip_prefix$$ (localized_dom_common.cljc:61)
    at core.cljs:4678
    at core.cljs:4678
    at $JSCompiler_StaticMethods_sval$$ (core.cljs:3392)
    at $cljs$core$LazySeq$$.$JSCompiler_prototypeAlias$$.$cljs$core$ISeqable$_seq$arity$1$ (core.cljs:3446)
    at $cljs$core$seq$$ (core.cljs:1208)
    at $clojure$string$join$cljs$0core$0IFn$0_invoke$0arity$02$$ (string.cljs:109)
    at $fulcro$client$alpha$localized_dom_common$combined_classes$$ (localized_dom_common.cljc:47)
$clojure$string$replace_all$$ @ string.cljs:34
$clojure$string$replace$$ @ string.cljs:71
$strip_prefix$$ @ localized_dom_common.cljc:61
(anonymous) @ core.cljs:4678
(anonymous) @ core.cljs:4678
$JSCompiler_StaticMethods_sval$$ @ core.cljs:3392
$JSCompiler_prototypeAlias$$.$cljs$core$ISeqable$_seq$arity$1$ @ core.cljs:3446
$cljs$core$seq$$ @ core.cljs:1208
$clojure$string$join$cljs$0core$0IFn$0_invoke$0arity$02$$ @ string.cljs:109
$fulcro$client$alpha$localized_dom_common$combined_classes$$ @ localized_dom_common.cljc:47
(anonymous) @ localized_dom_common.cljc:79
$fulcro$client$alpha$localized_dom_common$fold_in_classes$$ @ localized_dom_common.cljc:79
$fulcro$client$alpha$localized_dom_common$add_kwprops_to_props$$ @ localized_dom_common.cljc:93
(anonymous) @ localized_dom.cljs:43
$fulcro$client$alpha$localized_dom$macro_create_element$cljs$0core$0IFn$0_invoke$0arity$03$$ @ localized_dom.cljs:43
$fulcro$client$alpha$localized_dom$a$cljs$0core$0IFn$0_invoke$0arity$0variadic$$ @ localized_dom.cljs:50
(anonymous) @ pagination.cljc:119
(anonymous) @ core.cljs:4336
(anonymous) @ core.cljs:4336
$JSCompiler_StaticMethods_sval$$ @ core.cljs:3392
$JSCompiler_prototypeAlias$$.$cljs$core$ISeqable$_seq$arity$1$ @ core.cljs:3446
$cljs$core$seq$$ @ core.cljs:1208
$cljs$core$es6_iterator$$ @ core.cljs:1287
$cljs$core$LazySeq$$.(anonymous function) @ core.cljs:3458
g @ traverseAllChildren.js:99
e.exports @ traverseAllChildren.js:173
instantiateChildren @ ReactChildReconciler.js:75
_reconcilerInstantiateChildren @ ReactMultiChild.js:192
mountChildren @ ReactMultiChild.js:225
_createInitialChildren @ ReactDOMComponent.js:704
mountComponent @ ReactDOMComponent.js:523
mountComponent @ ReactReconciler.js:46
mountChildren @ ReactMultiChild.js:237
_createInitialChildren @ ReactDOMComponent.js:704
mountComponent @ ReactDOMComponent.js:523
mountComponent @ ReactReconciler.js:46
mountChildren @ ReactMultiChild.js:237
_createInitialChildren @ ReactDOMComponent.js:704
mountComponent @ ReactDOMComponent.js:523
mountComponent @ ReactReconciler.js:46
performInitialMount @ ReactCompositeComponent.js:371
mountComponent @ ReactCompositeComponent.js:258
mountComponent @ ReactReconciler.js:46
updateChildren @ ReactChildReconciler.js:122
_reconcilerUpdateChildren @ ReactMultiChild.js:212
_updateChildren @ ReactMultiChild.js:311
updateChildren @ ReactMultiChild.js:298
_updateDOMChildren @ ReactDOMComponent.js:943
updateComponent @ ReactDOMComponent.js:761
receiveComponent @ ReactDOMComponent.js:723
receiveComponent @ ReactReconciler.js:125

mitchelkuijpers14:03:53

fulcro-2.4.4-nf-SNAPSHOT does no force, but fixes a bug in localized-dom. 2.4.4-SNAPSHOT

mitchelkuijpers14:03:02

So I mean the nf-SNAPSHOT version

wilkerlucio14:03:24

ah, didn't knew about that, thanks for clarifying

tony.kay14:03:17

OK, well, good to know that forcing the children fixes it, but the cases I thought would break don’t so if you have a simple expression even that you know will break, I’d add it to my tests.

mitchelkuijpers15:03:00

Don't know if this helps but it only loses the shared state

tony.kay15:03:39

Yeah, I tried shared state stuff in lazy seqs, and still could not get a failure…I’m sure it’s something silly. But anyway, 2.4.4 released

mitchelkuijpers13:03:27

Thank you for your help @thheller i could at lease re-test with simple optimizations in 7 seconds instead of 60 😛

thheller14:03:46

ah ... the dev version of react checks everything when React.createElement is called. this would force the lazy-seq of map. this is not done in the react production version.

thheller14:03:19

so it probably expands at the wrong time. makes sense if mapv fixed it

tony.kay14:03:16

@danielstockton So, I share some of your surface opinions: Fulcro contains what could be split out into several libraries. When it was Untangled, it was exactly that: client, server, websockets, css, etc. The advantage was in PR: the Clojure community likes little pieces. The disadvantages are: - Tight integration is very difficult or impossible. I’m, in fact, integrating fulcro-css in the next version because it allows me to supply better DOM integration without circular library references. - However, many of the components are, in fact, completely optional. i18n is integrated, but you can choose your own. bootstrap3 is there for convenience, but is a standalone ns that could easily be it’s own library, etc., etc. - The reason most of these “optional” things are included is for my own convenience: It’s a pain in the ass to maintain 6 different libraries, with 6 different test suites, and 6 different releases, etc. We have Closure. It’ll strip out the stuff you don’t use. - I realize that having it all together makes entry seem a bit more overwhelming. That said, the real things I would hope you’re concerned about are having to understand things like “how loads and targeting works”. Again, the solution in Fulcro is intended to be general, but there are some compromises (not in terms of generality, but in terms of what Om Next was trying to allow). I’ve talked about those at length in many many places, so I’m not going to repeat them. I will mention that the most significant, customizing the client parser, is now completely doable, though I still don’t advise it.

tony.kay14:03:54

If your complaint boils down to “the docs intimidate me”, I hear you…I keep trying to make them less so.

tony.kay14:03:23

that said, I personally find the “tiny library” mentality a weakness and strength of the Clojure community. It’s also a weakness and strength of other communities like NPM. At its core Fuclro contains Om Next (3500 LOC), and then about 3500 of Fulcro-specific stuff stacked around it to supply the “missing pieces” (parser, plumbing, glue, loading story).

tony.kay14:03:44

The rest of the code in Fulcro is completely optional and can be ignored if you don’t need it.

tony.kay14:03:34

Also, you’d be very hard-pressed, I think, to come up with a general story for adding in the required missing pieces of Om Next in less code…but you’re welcome to try 🙂

👍 4
danielstockton15:03:41

It's a fair point about tight integration being difficult otherwise, and that's mainly why I didn't mean it as a criticism. As you said, there are advantages and disadvantages of both approaches. I suppose it does boil down to the fact that "the docs intimidate me" and I'm just looking for an easy way in. I do also worry that some of the missing pieces and plumbing are not necessary in all applications, but I understand that fulcro is aimed at fairly complex applications where most of it is. It would be great to have a gentler introduction that focuses more on core, and leaves the optional/advanced things to be discovered as required. Anyway, I hope the community can take on some of the work ("The reason most of these “optional” things are included is for my own convenience..."), because it seems like you're doing a great job of solving everyones problems and you probably deserve a holiday 😄

tony.kay15:03:14

Did you try the YouTube videos? I personally find those easier in some senses

tony.kay15:03:58

but yeah, perhaps I should re-work the getting started chapter of the book

tony.kay15:03:17

@mitchelkuijpers sounds like we lost force-children on DOM…I’ll look at that. Can you confirm that shared isn’t working, or is it just DOM that isn’t working?

danielstockton15:03:21

I didn't, mainly because I'm always short of time and looking to get straight to the point. Text can be easier to jump in and out of, without requiring a lengthy period of concentration. To be clear, I find the docs intimidating in the sense of volume + lack of focus, as opposed to the concepts. I feel like I understand the concepts and what fulcro wants to achieve pretty well, I just can't fit the whole system in my head and decide whats essential/optional/can be replaced. This adds a barrier to acceptance, because I feel like I have to buy into everything at once.

tony.kay15:03:58

I try to keep the videos to 20 mins, and you can always watch them 2x speed. I hear you about the docs, though. Some editing would help. Perhaps even a separate doc that is minimal and gets you going, a cheat sheet that tells you what’s “required” and what’s optional, with links to the main doc might also be helpful.

danielstockton15:03:34

Yep, I think a minimal getting started hello world would help a lot

mitchelkuijpers15:03:48

I'm checking that now @tony.kay

mitchelkuijpers15:03:38

Just confirmed only fails with alpha dom @tony.kay

tony.kay16:03:24

@danielstockton Thanks for the feedback. I’ll add that to the list 🙂

tony.kay17:03:38

@mitchelkuijpers Try 2.4.4-SNAPSHOT and let me know if that fixes it. I didn’t change localized-dom, just alpha.dom

mitchelkuijpers19:03:30

This fixes it without needing mapv

mitchelkuijpers17:03:04

Oh we use localized dom, but will try with alpha.dom

mitchelkuijpers17:03:02

Btw, shout-out to @thheller shadow-cljs release app --debug is amazing for a developer, for debugging stuff like this

tony.kay19:03:46

@mitchelkuijpers ok, I’ll fix localized as well and push a new version

mitchelkuijpers19:03:54

@tony.kay Awesome, do you still want a minimal repro?

tony.kay19:03:33

if that fixes it, it’s all good

👍 4
mitchelkuijpers13:03:08

2.4.4-SNAPSHOT works perfectly with the other NF version I still get:

Uncaught TypeError: $s$jscomp$122$$.replace is not a function
    at $clojure$string$replace_all$$ (string.cljs:34)
    at $clojure$string$replace$$ (string.cljs:71)
    at $strip_prefix$$ (localized_dom_common.cljc:61)
    at core.cljs:4678
    at core.cljs:4678
    at $JSCompiler_StaticMethods_sval$$ (core.cljs:3392)
    at $cljs$core$LazySeq$$.$JSCompiler_prototypeAlias$$.$cljs$core$ISeqable$_seq$arity$1$ (core.cljs:3446)
    at $cljs$core$seq$$ (core.cljs:1208)
    at $clojure$string$join$cljs$0core$0IFn$0_invoke$0arity$02$$ (string.cljs:109)
    at $fulcro$client$alpha$localized_dom_common$combined_classes$$ (localized_dom_common.cljc:47)
$clojure$string$replace_all$$ @ string.cljs:34
$clojure$string$replace$$ @ string.cljs:71
$strip_prefix$$ @ localized_dom_common.cljc:61
(anonymous) @ core.cljs:4678
(anonymous) @ core.cljs:4678
$JSCompiler_StaticMethods_sval$$ @ core.cljs:3392
$JSCompiler_prototypeAlias$$.$cljs$core$ISeqable$_seq$arity$1$ @ core.cljs:3446
$cljs$core$seq$$ @ core.cljs:1208
$clojure$string$join$cljs$0core$0IFn$0_invoke$0arity$02$$ @ string.cljs:109
$fulcro$client$alpha$localized_dom_common$combined_classes$$ @ localized_dom_common.cljc:47
(anonymous) @ localized_dom_common.cljc:79
$fulcro$client$alpha$localized_dom_common$fold_in_classes$$ @ localized_dom_common.cljc:79
$fulcro$client$alpha$localized_dom_common$add_kwprops_to_props$$ @ localized_dom_common.cljc:93
(anonymous) @ localized_dom.cljs:43
$fulcro$client$alpha$localized_dom$macro_create_element$cljs$0core$0IFn$0_invoke$0arity$03$$ @ localized_dom.cljs:43
$fulcro$client$alpha$localized_dom$a$cljs$0core$0IFn$0_invoke$0arity$0variadic$$ @ localized_dom.cljs:50
(anonymous) @ pagination.cljc:119
(anonymous) @ core.cljs:4336
(anonymous) @ core.cljs:4336
$JSCompiler_StaticMethods_sval$$ @ core.cljs:3392
$JSCompiler_prototypeAlias$$.$cljs$core$ISeqable$_seq$arity$1$ @ core.cljs:3446
$cljs$core$seq$$ @ core.cljs:1208
$cljs$core$es6_iterator$$ @ core.cljs:1287
$cljs$core$LazySeq$$.(anonymous function) @ core.cljs:3458
g @ traverseAllChildren.js:99
e.exports @ traverseAllChildren.js:173
instantiateChildren @ ReactChildReconciler.js:75
_reconcilerInstantiateChildren @ ReactMultiChild.js:192
mountChildren @ ReactMultiChild.js:225
_createInitialChildren @ ReactDOMComponent.js:704
mountComponent @ ReactDOMComponent.js:523
mountComponent @ ReactReconciler.js:46
mountChildren @ ReactMultiChild.js:237
_createInitialChildren @ ReactDOMComponent.js:704
mountComponent @ ReactDOMComponent.js:523
mountComponent @ ReactReconciler.js:46
mountChildren @ ReactMultiChild.js:237
_createInitialChildren @ ReactDOMComponent.js:704
mountComponent @ ReactDOMComponent.js:523
mountComponent @ ReactReconciler.js:46
performInitialMount @ ReactCompositeComponent.js:371
mountComponent @ ReactCompositeComponent.js:258
mountComponent @ ReactReconciler.js:46
updateChildren @ ReactChildReconciler.js:122
_reconcilerUpdateChildren @ ReactMultiChild.js:212
_updateChildren @ ReactMultiChild.js:311
updateChildren @ ReactMultiChild.js:298
_updateDOMChildren @ ReactDOMComponent.js:943
updateComponent @ ReactDOMComponent.js:761
receiveComponent @ ReactDOMComponent.js:723
receiveComponent @ ReactReconciler.js:125