fulcro

Book: http://book.fulcrologic.com, Community Resources: https://fulcro-community.github.io/, RAD book at http://book.fulcrologic.com/RAD.html
currentoor 2021-01-29T00:08:27.107400Z

i believe it's meant to be the pro paid version of guardrails

currentoor 2021-01-29T00:08:53.107600Z

similar to how intelliJ has a free lite version and a pro paid version

tony.kay 2021-01-29T01:53:17.107800Z

You code in Guardrails. Copilot uses the same guardrails info to then do code analysis while you’re editing (instead of needing you to run the code)

tony.kay 2021-01-29T01:53:57.108Z

So, copilot is an add-on tool with IntelliJ integration that is sorta like clj-kondo, but understands the data better, so it can find more interesting errors.

🆒 1
2021-01-29T04:40:27.110Z

sanity checking what appears to be a pretty weird bug, in the following example which is run in my :client-did-mount cb, the load! call won’t run until the transact! call finishes and returns to the client, correct?

(fn [mounted-app]
  (comp/transact!
    mounted-app
    `[(current-user/create-user-session ~{:user/id 123})])
  (df/load!
    mounted-app
    [:user/id 123]
    User
    {:target [:current-user]}))

Jakub Holý 2021-01-29T07:51:50.110200Z

transact!! is special and only refreshes the this component I believe. Cannot you use transact! ?

Jakub Holý 2021-01-29T07:53:16.110400Z

start from the RAD template and delete all the RAD stuff. Inline the code that creates app from RAD. That is likely to work.

👍 1
Jakub Holý 2021-01-29T07:54:45.110600Z

I believe the action of the mutation is executed before the load! but if there is a remote part to the mutation, that is triggered but not waited for.

avocade 2021-01-29T11:17:59.117200Z

Hey guys, a question regarding globally handling stuff we send to, or ask for, from the backend: Is there a way to always elide certain keywords in loads and mutations, like what we get when using :without in a load!? So we don't have to remove common things explicitly. There is an existing method in fulcro of adding a :ui/ prefix to keys, which maybe could be allowed to be extended? Preferably allowing both keywords and predicate functions

avocade 2021-02-02T13:18:42.217700Z

Thanks, will check those out 👍

Jakub Holý 2021-01-29T11:40:32.121900Z

FYI I have now published https://github.com/fulcro-community/guides/blob/main/minimalist-fulcro-tutorial/index.adoc - but your comments and suggestions are still very welcome! I have also updated https://github.com/fulcro-community/guides/blob/main/learning-fulcro.adoc to include it though I am not sure where exactly it should go. Now it is essentially as the first learning step, which is OK because it is intended as such - but the problem is that it focuses only on "how" and does not explain why Fulcro is the way it is. I feel that the reader should be exposed to the rationale for Fulcro early but I am not sure where to point her/him. https://fulcro.fulcrologic.com/ is too high-level, https://book.fulcrologic.com/#_fulcro_from_10000_feet in a way gets in too much detail and includes some of the same things as in the Tutorial. Any suggestions?

👍 1
🙏 2
🎉 4
2021-01-30T13:05:23.150400Z

Thanks, I have started reading it. Looks good so far. Small spelling mistake in last sentence of Prerequisities: 'vlue proposition' should be 'value proposition' I can file issue/pr if you prefer.

Jakub Holý 2021-01-30T19:18:12.185500Z

thanks, tkovis already fixed it

yubrshen 2021-02-02T05:27:25.208300Z

@holyjak Thanks very much for the minimalist tutorial! I'm studying in details. I especially appreciate the section on Prerequisites, which is really I need. I'm studying "Key concepts and elements" now. It seems that the following might have a typo App A reference to the current Fulcro application, containing configuration, the client DB, etc. Produced by app/fulcro-app and used when calling transact! or load! when a component's this is not available. Referred to as app in code samples. Maybe, this should be data ?

yubrshen 2021-02-02T05:44:31.208600Z

@holyjak For Client DB The client-side cache of data. It is a map of maps: entity name (e.g. `:person/id`) → entity id value (e.g. `123`) → properties of the entity (e.g. `{:person/id 123, :person/fname "Jo", :person/address [:address/id 3]}`). (For convenience, we use the name of the id property as the "name" of the entity - thus `:person/id`, `:user/username`.) I feel the above still somehow convoluted. I haven't figured out. I wonder if if would be better to separate the description of the abstract structure, then follow with a concrete data samples of a client DB? If the client DB is a map, what are the keys of this map (the highest level)? The entity, such as person, car, etc.? As values of the highest map, themselves maps, what are the maps (keys, values)? For entity person, the map of keys of id, name, age, cars, etc.?

Jakub Holý 2021-02-02T08:01:04.210200Z

@yubrshen You are welcome 🙂 1) What typo? What do you mean by "`this` should be data"? It refers to the first argument of defsc, it is traditionally called this . 2) Thanks, I will think about simplifying. > If the client DB is a map, what are the keys of this map (the highest level)? The entity, such as person, car, etc.? As the text says: "entity name (e.g. `:person/id`)" > As values of the highest map, themselves maps, what are the maps (keys, values)? they are maps from "entity id value (e.g. `123`) → properties of the entity" > For entity person, the map of keys of id, name, age, cars, etc.? Yes. Or, in my example, :person/id, :person/fname, :person/address

yubrshen 2021-02-04T06:26:59.235300Z

@holyjak Thanks! I forgot the special this

yubrshen 2021-02-07T15:28:00.265300Z

@holyjak With English no as my native language, I feel the following for the description of Client DB is clearer to me:

The client-side cache of data. It is
a map of maps:
entity name  → entity id value  → properties of the entity

For convenience, we
use the name (keyword) of the id property
as the "name" of the entity 
thus :person/id for the entity Person

For example,
:person/id -> {:person/id 123, :person/fname "Jo", :person/address [:address/id 3]}

It is fed by initial data and loading data from the backend and can be changed by mutations.
It's just a refactoring, to make it less "complex".

Jakub Holý 2021-02-08T09:21:35.276Z

Thank you! Applied 🙂

Jakub Holý 2021-01-29T11:42:43.122200Z

yes, provide your own replacement for default default-global-eql-transform https://github.com/fulcrologic/fulcro/blob/develop/src/main/com/fulcrologic/fulcro/application.cljc#L157

Jakub Holý 2021-01-29T11:43:24.122500Z

see how RAD does that to exclude f.ex. default-network-blacklisthttps://github.com/fulcrologic/fulcro-rad/blob/develop/src/main/com/fulcrologic/rad/application.cljc#L23

2021-01-29T17:16:20.125600Z

Hey. thanks for this. very succinct

❤️ 1
➕ 1
Tuomas 2021-01-29T17:33:19.126Z

I myself really like how rust made touched on rationale in it's foreword https://doc.rust-lang.org/book/foreword.html and introduction https://doc.rust-lang.org/book/ch00-00-introduction.html#who-rust-is-for I really think you should start with why

👀 1
futuro 2021-01-29T22:32:38.132800Z

The first time Fulcro clicked for me was in the interview with Jacek Schae, specifically because Tony spoke about the original impetus and then the idioms and foundational concepts. I’m afraid I don’t have much in the way of concrete suggestions, but maybe those interviews would help. https://podcasts.apple.com/us/podcast/clojurescript-podcast/id1461500416?i=1000479361034

👂 1