om

Please ask the channel first, not @dnolen directly!
petterik 2017-03-27T01:16:10.906218Z

@sova Which om.next version are you on? There was one SSR fix that had to do with html-escaping the :style map (css values). React usually says exactly where the checksum missmatches. What does your error say?

anmonteiro 2017-03-27T01:30:11.979512Z

Server-side rendering (with checksums getting picked up) has been fairly stable since September when Cellophane was merged in Om Next

anmonteiro 2017-03-27T01:30:29.981284Z

AFAIK there have been like 2 or 3 fixes to SSR since then

2017-03-27T10:04:57.283996Z

is there a reference frontend/backend om.next app? something I could use to learn om.next?

2017-03-27T10:05:07.285927Z

ideally with SSR, backend api, etc

baptiste-from-paris 2017-03-27T10:14:09.399732Z

@mping you have todomvc by David Nolen if I remember well

2017-03-27T10:14:58.409945Z

@baptiste-from-paris is that for om.next? also dont think there is backend involved

baptiste-from-paris 2017-03-27T10:18:05.448318Z

yep there is

baptiste-from-paris 2017-03-27T10:18:18.450973Z

https://github.com/swannodette/om-next-demo

baptiste-from-paris 2017-03-27T10:18:35.454250Z

with a datomic back-end

baptiste-from-paris 2017-03-27T10:18:53.457645Z

you also have some nice tutos by the untangled team

baptiste-from-paris 2017-03-27T10:20:01.470828Z

it’s about untangled but it can help you understand om.next

2017-03-27T11:20:52.163703Z

Is there a "proper way" to deal with state that isn't in your app-state map in Om? I'm making a simple music player with Om.next and howler.js. To play/pause audio and so on I need to call methods on js objects. Right now I'm just calling them from action thunks in my mutate function but I don't know if there's a better way to do it since I guess you lose stuff like going back in history.

2017-03-27T11:24:47.206189Z

@emiluren Is there no way to make everything completely deterministic?

2017-03-27T11:27:13.232876Z

Here's a general question to the channel: I have a :start and :end on my app-state that determines the time period for all reports and I have a problem getting the right follow-on reads to run, every time I change them. All these reads are in the :reports/ namespace. Do you think it's a good idea to read the current root query, transform it to ast, extract all the :reports/ keys and add those as trailing reads to the transact which updates start/end?

2017-03-27T11:32:43.294385Z

@danielstockton I don't know. Maybe I could make some sort of data format that describes the state of an audio object and make sure it is in that state in my render function or something but it feels hacky and hard to get right

2017-03-27T11:34:08.309627Z

@emiluren render or other lifecycle methods. Anyway, I think that's what you'd have to do or else accept that some things are outside of deterministic history.

2017-03-27T11:34:40.315538Z

In order for you to retain proper history, you'd have to do this one way or another.

2017-03-27T11:34:59.319157Z

Ok, thank you for your help 🙂

2017-03-27T11:42:16.401694Z

The other way I can think to do this is to define all the report reads in one place, define which are acceptible for a given route, and then check the route before firing off requests in my parsers.

2017-03-27T11:42:31.404504Z

That might be simpler actually.

anmonteiro 2017-03-27T14:06:38.758259Z

@mping same version of todomvc but with SSR https://github.com/anmonteiro/om-next-fullstack

👍 3
peeja 2017-03-27T16:51:59.559925Z

@emiluren That actually sounds best and not hacky at all to me. I mean, you'll probably need to do a little fudging to make it work with an external object that's changing state in real time, so there may be some hacks there, but the approach in general sounds to me like the right application of React principles.

gardnervickers 2017-03-27T17:03:24.808151Z

@anmonteiro We started using plomber for our dev build and would love to have it published at some point. Totally understandable if you don’t want to have to maintain that, just mentioning because I saw there’s a note about it in the README 😄

anmonteiro 2017-03-27T17:04:20.828531Z

@gardnervickers 🙂 I just didn’t publish it because I thought nobody would use it

anmonteiro 2017-03-27T17:04:42.836655Z

also the name was a stupid pun at the time

gardnervickers 2017-03-27T17:05:02.843917Z

It’s proved very useful for tracking down problems where pathopt fails and triggers a root render.

anmonteiro 2017-03-27T17:05:09.846302Z

oh wth, I even have docs for it

anmonteiro 2017-03-27T17:05:21.850963Z

I don’t remember this being in such a good state

anmonteiro 2017-03-27T17:05:25.852719Z

cutting a release now

👍 3
gardnervickers 2017-03-27T17:05:26.852982Z

Heh

anmonteiro 2017-03-27T17:14:44.047390Z

@gardnervickers https://clojars.org/plomber

1
gardnervickers 2017-03-27T17:15:28.062496Z

Thanks!

anmonteiro 2017-03-27T17:18:08.117934Z

I wonder how you found it though

anmonteiro 2017-03-27T17:18:24.123960Z

I never really advertised Plomber 🙂

gardnervickers 2017-03-27T19:52:17.341692Z

@anmonteiro I was looking through Compassus a while back and must have stumbled upon it somehow and it’s stuck in my brain 😄

gardnervickers 2017-03-27T19:53:34.367620Z

Does the presence of a link in a query have an effect on if a component can utilize path optimization?