Fork me on GitHub
#untangled
<
2017-01-25
>
tony.kay01:01:37

Just published a new tutorial video (part of a series I'm working on): Untangled/Om Next In The Large.

tony.kay01:01:12

Part 1 covers the very common and popular problem of structuring your app (Union queries, including nesting them), and HTML5 routing (with params)

tony.kay01:01:28

Source code and helper macros included and linked from the video description

claudiu07:01:06

awesome, thank you 🙂

doddenino09:01:19

Hi guys! I'm interested in an overview on untangled, but on the website I can only find detailed guides a videos

fatihict13:01:18

@doddenino Here you can find the documentation for Untangled: http://untangled-web.github.io/untangled/docs.html. The Developer's guide was really helpful for a quick overview for me, especially the Quick tour.

doddenino15:01:16

Thanks guys 🙂 I will check the videos

jasonjckn22:01:19

@tony.kay what's the difference between your routing approach and just the 3 line secretary + html5 routing approach ?

tony.kay22:01:58

um, remind me

tony.kay22:01:17

my approach is about tying the html5 routing to an arbitrarily large set of unions in Om

tony.kay22:01:34

in a structured way you can easily extend

tony.kay22:01:40

next video coming later today

jasonjckn22:01:54

@tony.kay in our app, we make links <a href=/foobar> when the user clicks that link secretary dispatches our route handler which in turn calls transact!

tony.kay22:01:13

right, no difference there, and I think mine is 2-3 lines for that part

tony.kay22:01:29

the rest of it is about large applications

tony.kay22:01:49

the fact that you want your queries to end up small, which means lots of union queries...which in turn are finiky

tony.kay22:01:23

so, a macro or two and some invented functions the help make the overall structure/union switching declarative

tony.kay22:01:47

such-and-such a route switches this set of well-known union (routers) to the correct spot

jasonjckn22:01:54

ok, i'll take a deeper look at your solution, our app is structured like your TabUnion recipe

tony.kay22:01:03

yep, like that, but bigger

jasonjckn22:01:05

one giant Root agg TabUnion agg everything else

tony.kay22:01:07

thus "In The Large" 🙂

tony.kay22:01:16

yes, you can do it that way

tony.kay22:01:52

Is that composing well for you? Don't you have sub-screens that come in and out of view...or did you flatten everything?

jasonjckn22:01:02

everything is flattened

jasonjckn22:01:10

for better or for worse

tony.kay22:01:20

Ah. That seems less ideal for a large app in terms of composition

jasonjckn22:01:00

yes perhaps i'm glad you fixed that nested Union bug, it's definitely nice to have this option on the table

tony.kay22:01:12

yeah, sorry about that...did that bite you?

tony.kay22:01:19

perhaps that is why you felt you needed to leave it flat

jasonjckn22:01:54

I don't think we hit the bug yet, I haven't trained the others on the team in Unions yet which is probably why lol

jasonjckn22:01:08

but had the known they probably would have used it as our app is growing quite complex

tony.kay22:01:10

well, the macro makes it much nicer. Check out the video and source

baris22:01:34

we use the same approach: a macro which generates one big flatten union query - router component (like the tabunion example)

jasonjckn22:01:08

yes we also generate the union query

tony.kay22:01:30

the big flat is fine for a lot of cases...I was assuming though that people might have complicated screens that needed to compose in sub-screens..e.g. which include part of the parent

tony.kay22:01:34

which indicates a tree

tony.kay22:01:23

side-by-side things that can change independently, etc

jasonjckn22:01:32

complex applications is why we picked untangled so happy to see solutions like this even if i don't need them yet

tony.kay22:01:55

sorta like the chat section in gmail, overlays, etc

tony.kay22:01:19

one of our apps got really laggy because complex nested screens were not using unions

baris22:01:34

@tony.kay - which topics are u covering in the next video?

tony.kay22:01:57

had not decided 🙂 I've got code written to show component development and screen development. I'll probably start with component

tony.kay22:01:08

since I have more to show there

tony.kay22:01:13

at least so far 🙂

baris22:01:42

the usage of devcards -> workflow during development?

tony.kay22:01:02

yes, but with some specific tips and workflow hints

tony.kay22:01:17

rather: yes

tony.kay22:01:31

I have an HTML->React converter too

tony.kay22:01:49

makes pulling things like bootstrap examples a copy/paste exercise

baris22:01:03

awesome…sounds like a very promising and helpful ressource for beginners like me

baris22:01:00

I couldn’t find any good ressource how devcards could speedup my development workflow

tony.kay22:01:08

I'm wanting to include @therabidbanana tips from this blog post https://medium.com/adstage-engineering/how-we-test-our-full-stack-clojure-app-b18d79ee9e00#.3v0ps49ty in somehow as well. I'll probably just refer people to his post in the description and verbally. His idea on using devcards for automated UI testing is cool

tony.kay22:01:41

it's just visual regression testing, but it's a great combo of devcards and the general idea