It seems in nicegui you build the initial UI, and then mutate various parts of it in event callbacks. It seems similar to traditional dom programming.
Hyperdiv expresses UI declaratively based on state. As state changes, the app re-runs, producing a changed UI.