This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-12-09
Channels
- # adventofcode (93)
- # announcements (11)
- # babashka (7)
- # babashka-sci-dev (17)
- # beginners (73)
- # biff (7)
- # calva (3)
- # cider (1)
- # clj-kondo (160)
- # clj-together (12)
- # clojure (44)
- # clojure-art (2)
- # clojure-europe (12)
- # clojure-losangeles (1)
- # clojure-nl (3)
- # clojure-norway (22)
- # clojure-uk (2)
- # clojurescript (8)
- # clr (1)
- # cursive (6)
- # data-science (1)
- # datomic (1)
- # emacs (6)
- # events (1)
- # exercism (1)
- # fulcro (6)
- # graphql (2)
- # introduce-yourself (1)
- # lsp (18)
- # nrepl (7)
- # off-topic (45)
- # polylith (25)
- # portal (25)
- # practicalli (3)
- # re-frame (14)
- # reagent (28)
- # reitit (2)
- # releases (2)
- # shadow-cljs (73)
- # sql (11)
- # tools-deps (12)
- # transit (4)
- # xtdb (4)
Hey everyone, I'm thinking about adopting Fulcro for an upcoming project. Coming from the React / Node Microservice universe, I'm used to fully decoupled front-ends and sessionless back-ends. I don't see any reason why Fulcro can't be built that way, but the template seems pretty opinionated on it. Is there a recommendation on how to split up the template repo, or would I be better off starting from scratch and not using the template at all?
All Fulcro cares about is that when you talk to a remote, you have a remote that complies with the interface it needs. Fulcro itself sends EQL to the remote, and expects the remote to give back a properly-shaped result. HOW you talk to servers and manage sessions is completely up to you. The template gives you a starter server for convenience.
(a remote, here, is a bit of code that you install on the Fulcro application…there are two stock implementations: one for http POST operation and one for websockets…see their source code if you feel you need something addl)
Thanks for the quick reply @U0CKQ19AQ what do you mean by "installed on the Fulcro application"? I was hoping to build a system where the frontend was delivered statically from a CDN, and the backend (pathom) would be running separately in some app service. I think you mean the remote would be configured in the frontend, and the backend could be anything that returns a properly shaped result
Yes, Tony meant configuring the remote on the app, as in https://github.com/fulcrologic/fulcro-template/blob/8986927d1e7f2d6c6bb06daffa260bb7990302b6/src/main/app/application.cljs#L25-L27 Beware that Fulcro is quite different from other approaches and takes some time getting used to. Mainly people expect things to be much more complex than they are 🙂 If you want to play a little first, you can check out https://github.com/holyjak/minimalist-fulcro-template-backendless or https://github.com/holyjak/minimalist-fulcro-template . And of course I must mention https://fulcro-community.github.io/guides/tutorial-minimalist-fulcro