Fork me on GitHub
#fulcro
<
2018-02-08
>
drewverlee02:02:19

One thing i haven’t worked out yet is if fulcro’s graph rest queries translats directly into datomic queries or if there is still a transformation layer. Or if not, why and if its possible.

tony.kay02:02:03

@drewverlee the graph syntax is similar to datomic’s pull API. Many queries can run directly. Unions have no equivalent in Datomic, and idents have to be translated to an entity query followed by a pull.

tony.kay02:02:11

The rest of the syntax is Datomic pull…so, if you’re not using ident-based joins or unions in a given server query, then it can run. Assuming your client query graph matches your server database graph structure and the keywords match in name, etc. Of course

tony.kay02:02:27

syntactically, it is usually the case that the Fulcro query can run as a pull

mitchelkuijpers08:02:13

We will try it out @tony.kay thank you!

chrisblom11:02:02

how can I use route params in the ident of a router?

chrisblom11:02:33

which defines a route that uses [:status-report :param/report-id] as the target screen, but in the ReportRouter's ident fn, :id is used. I don't see how I can get the :report-id from the route-params into the props used by the router

donmullen15:02:04

Anyone using Emacs/Cider with Fulcro? I’m trying to set up so that I can do cider-jack-in-clojurescript - but run the custom (start-figwheel) that is in src/dev/user.clj. Usually for figwheel/cider this variable is set to enable using figwheel:

(setq cider-cljs-lein-repl
      "(do (require 'figwheel-sidecar.repl-api)
           (figwheel-sidecar.repl-api/start-figwheel!)
           (figwheel-sidecar.repl-api/cljs-repl))")

maridonkers15:02:29

I always use the manual approach to connect to a cljs repl in emacs, see: http://www.photonsphere.org/posts-output/2017-12-19-fulcro-emacs-cider/

donmullen15:02:51

@U0SSNQ659 - and that setup allows emacs to send recognize the clojurescript repl when in cljs files and clojure when in clj files?

maridonkers16:02:48

Which way to go with .cljc files?

donmullen16:02:46

Good question!

donmullen19:02:39

Yes - evidently the default is to send to both open repls (cljs and clj) if in a cljc file. See bottom of https://cider.readthedocs.io/en/latest/up_and_running/

maridonkers19:02:07

As the great philosopher George Clooney used to say: "what else" :-)

donmullen15:02:45

Somewhat related - @tony.kay - the fulcro basic videos projects needs [cider/cider-nrepl "0.16.0"] added to the project.clj plugins.

mitchelkuijpers15:02:23

@donmullen We use a .dir-locals.el file per project with for example:

((nil . ((projectile-project-type . lein-test)
         (eval . (progn
                   (require 'cider)
                   (setq projectile-create-missing-test-files t)
                   (setq cider-cljs-lein-repl "(start-cljs-repl)"))))))
That way you can use cider-jack-in-clojurescript with different commands

tony.kay17:02:50

@chrisblom parameters are a feature of the routing tree support. Keep reading. Basically when you give ssomething that looks like a bidi match, the :route-params are mapped onto the :param/kw elements.

tony.kay17:02:19

@donmullen Thanks. I you want to push a tested PR glad to merge it. I don’t use cider, so I can’t easily test such a change.

tony.kay18:02:59

@mitchelkuijpers nevermind on the logging. I’m going to do it a different way.

tony.kay18:02:56

I’m backing out the recent logging changes from the branches. develop has been rebased. If you have a current clone or fork, sorry…you’ll get a forced update or two.

mitchelkuijpers18:02:38

@tony.kay had no time for it today, so no worries!