Ok, you talk about logic being on the server and the client. I thought you were saying that related logic was spread across different points from an architecture point of view, like "some in the event-log consumers", "some in the components", "some in the request handlers" etc. (these are just examples).
Khalid aka DjebbZ @Dj3bbZ On Wed, May 13, 2015 at 2:30 PM, Colin Yates <[email protected]> wrote: > Yeah, I didn't explain that second point well. Because of the lack of > (my experience with) web based tooling I typically have most of the > logic on the back end leaving the UI to be pure rendering only. With > the symmetry of CLJ and CLJS that technical barrier has disappeared. > > Case in point, I am just now coding logic which summarises the > criteria used to select the data you are seeing. Imagine a table with > a set of tabs, each tab allowing you to restrict some criteria and the > table shows you matching results. The logic to produce something like > "Viewing 132 out of 3423 results for location 1 and location 2, across > all woogies and non-active wibblies, ..." is less trivial then it > might sound. Previously I would have returned this as part of the > results returned from the server {:results [..] :total-count 3423 > :context "for location 1 ..."} where as now I am less nervous about > that logic living on the web tier. Of course, there are other concerns > for this case in point around data staleness (you don't want the > context being updated before the results are updated etc.). > > tldr - the symmetry of CLJ and CLJS make it easier (for me at least) > to put non-trivial logic on the front end > > > On 13 May 2015 at 13:06, Khalid Jebbari <[email protected]> wrote: > > I understand the relationship between state machines and event-log/CQRS. > A program could just translate the UI events into events stored in an event > log, and let them be consumed continually by a state machine. You would > basically reduce the events log using the state machine as a reduction > function. > > > > When you say logic end up in lot of different places, do you mean logic > that should be related ? I'd like to understand more about that point. > > > > -- > > Note that posts from new members are moderated - please be patient with > your first post. > > --- > > You received this message because you are subscribed to the Google > Groups "ClojureScript" group. > > To unsubscribe from this group and stop receiving emails from it, send > an email to [email protected]. > > To post to this group, send email to [email protected]. > > Visit this group at http://groups.google.com/group/clojurescript. > > -- > Note that posts from new members are moderated - please be patient with > your first post. > --- > You received this message because you are subscribed to a topic in the > Google Groups "ClojureScript" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/clojurescript/7STtgK5QiIc/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/clojurescript. > -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/clojurescript.
