Closed amirouche closed 6 years ago
No, it doesn't use virtual-dom.
The macro will actually modify the update()
method to insert the calls to gtk set_property()
whenever a model attribute is assigned (either with =
or with an operator like +=
).
This means that the following code won't trigger a view update:
self.model.string.push_str("test");
while the following will:
self.model.string += "test";
This module is responsible to add these statements.
Ok. But when the view is called, what happens? Isn't the current scene graph patched with the new view?
There's a similar code generation for when the view is created so that it gets the initial state.
TIA