Skip to content

Instantly share code, notes, and snippets.

@WolfgangSenff
Last active June 6, 2025 15:46
Show Gist options
  • Save WolfgangSenff/099f13c832ec28c1a017b7ee5bcd1e54 to your computer and use it in GitHub Desktop.
Save WolfgangSenff/099f13c832ec28c1a017b7ee5bcd1e54 to your computer and use it in GitHub Desktop.
Godot MVU-style views
var view = {
root = control({
mouse_filter = MOUSE_FILTER_IGNORE
}, [
vbox({ size_flags_horizontal = SIZE_EXPAND, size_flags_vertical = SIZE_SHRINK_CENTER },
[
label({ text = "Player Name:" }),
label({ text = data.player_name.value() })
]
)
]
)
}
var data = {
hp = bind_oneway(10),
player_name = bind_twoway("Player Name")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment