[13:09] topic: shadow dom [13:09] scribe: BenjamP [13:09] rniwa: hey, sorry i didn't make it down today [13:09] == BenjamP [~BenjamP@public.cloak] has quit [Ping timeout: 180 seconds] [13:10] something came up [13:10] dglazkov: let's spend time on imperative api [13:10] * rniwa sicking: we're talking about imperative API for insertion points [13:10] rniwa: imperative API ++ [13:10] == KenjiBX_ [~KenjiBX@public.cloak] has joined #webapps [13:11] https://gist.github.com/dglazkov/ce96f673b0b2ce7b8c55 [13:12] == jinsong [wjs@public.cloak] has joined #webapps [13:14] the following is based on the doc linked above- Distribution Callback section. [13:14] dglazkov: we don't know when to run the callback [13:14] * Yves bugzilla is up, rejoice! [13:15] ... this has to do with how the box trees compose. Previously, we don't have to compute style until later, we can defer it. But problem is we have to run it the callback when you query the property. [13:16] rniwa: I think it's worse [13:16] == KenjiBX [~KenjiBX@public.cloak] has quit [Ping timeout: 180 seconds] [13:17] dglazkov: we have an array or add/remove methods. The array can be the filter. The problem is the author has to implement the distribution algorithm by hand.
has to set a mutation observer. [13:17] == hallvors [~hallvors@public.cloak] has quit [Ping timeout: 180 seconds] [13:17] == KenjiBX_ [~KenjiBX@public.cloak] has quit [Ping timeout: 180 seconds] [13:18] ... another (bad) idea is selector-based routing. Insert children based on selector [13:18] https://www.w3.org/Bugs/Public/show_bug.cgi?id=18429#c4 [13:19] ,,, this bug shows combination of passive array and selector-based rounting [13:19] ... so 4 total ideas here. Looking for thoughts [13:19] rniwa: let's have a list of candidates and notify author when it changes. [13:20] dglazkov: we could get stuck in 2-resolution loop [13:22] rniwa: not necessarily. Distribution doesn't need to be synchronous. We could instead compose at the end and notify all. It's okay because we won't paint during the micro-task [13:23] dglaskov: we don't want it to return 0 because it hasn't rendered. [in steps], what is offset top? Would be zero. This gives ability to reason about what's happening when things are added to the DOM, and you'll see them later. [13:24] ... author won't know if it has run or not [13:24] rniwa: similar to custom elements unresolved state [13:24] ...don't want to expose timing in engine. Synchronous costs perf, async we'll have times when things aren't up to date [13:25] dglaskov: this doesn't matter for routing [13:25] ... conceptual model is css [13:26] ... run it at the end of micro-task. I don't think that's unreasonable. But let's make sure we not confusing users mental model [13:26] rniwa: selector-based routing has an expensive query, doesn't address random element use case [13:27] == trackbot [trackbot@public.cloak] has quit [Client closed connection] [13:27] == xiaoqian [xiaoqian@public.cloak] has quit [Client closed connection] [13:27] == jinsong [wjs@public.cloak] has quit [Client closed connection] [13:27] == xiaoqian [xiaoqian@public.cloak] has joined #webapps [13:27] dglaskov: random is solved by selectors. When you create a router you define random [13:28] == trackbot [trackbot@public.cloak] has joined #webapps [13:28] rniwa: you have to listen to mutations of your children [13:28] dglaskov: no you don't [13:29] rniwa: inserting elements should not break the selection [13:29] dglaskov: valid point [13:30] ... you'll sometime have ocasional inconsistency with imperative. That's okay. [13:30] ... style resolution after callback? [13:31] ... you could trigger it, but it doesn't typically need to run before callback [13:31] rniwa: there are times you want to stay in sync and have them happen at the same time [13:32] == jmajnert [~jmajnert@public.cloak] has left #webapps [] [13:33] dglaskov: insertion point needs an onDistrobution event [13:34] rniwa: I agree it's weird to get wrong offsetTop, but our options are limited [13:35] hayato: it's a tough issue [13:35] == sicking [~sicking@public.cloak] has quit [sicking] [13:35] dglaskov: if you choose imperative, it may be difficult, but that's ok [13:35] ... not sure if this is a problem in real life [13:36] ArtB: something about potatoes [13:36] * Yves post-prandial silence [13:36] +Bacon please [13:37] s/something about potatoes/carbos for lunch syndrome/ [13:37] topic: imports [13:37] https://gist.github.com/omo/9986103 [13:37] dglaskov: let's talk about blocking rendering [13:37] == sicking [~sicking@public.cloak] has joined #webapps [13:37] == skddc [~anonymous@public.cloak] has quit [Ping timeout: 180 seconds] [13:38] https://gist.github.com/omo/9986103 -> HTML Imports: Discussion over Async/Progressive Loading [13:38] ... imports are modeled after stylesheets [13:38] == alia [~alia@public.cloak] has joined #webapps [13:39] ... trying to enable asynchronous loading, but sometimes we have to block [13:40] ... if you have a script block in you doc, your loading imports will be sync with script. [13:41] ... without