monkberry icon indicating copy to clipboard operation
monkberry copied to clipboard

What magic is under the hood instead of virtual-dom?

Open davojan opened this issue 9 years ago • 7 comments
trafficstars

How the engine detects what DOM should be changed on update without virtual-dom?

davojan avatar Jul 11 '16 08:07 davojan

Why do you need Virtual DOM?

Mevrael avatar Sep 22 '16 12:09 Mevrael

Hi,

I'm going to write an article about how Monkberry works in next month. Will explain all there. Short answer is what templates compiled from this:

<div>
  ...
    <h1>{{ title }}</h1>
  ...
</div>

To something like this:

function (state) {
  h1.textContent = state.title;
}

And some king of "virtual dom" used on top/component level.

antonmedv avatar Sep 23 '16 17:09 antonmedv

@elfet did you complete your article? Wanna read :)

fliptheweb avatar Jan 03 '17 16:01 fliptheweb

@fliptheweb i'm always gonna to, but can not find time now :(

antonmedv avatar Jan 04 '17 05:01 antonmedv

@antonmedv did you finish the article? I'm really want to know the keys of monkberry.

lijinpengFj avatar Mar 22 '17 03:03 lijinpengFj

@lijinpeng7364 nope, sorry. A lot of work)

antonmedv avatar Mar 22 '17 06:03 antonmedv

@antonmedv ok, hope someday you can finish it.

lijinpengFj avatar Mar 22 '17 07:03 lijinpengFj