Change button`s text of a node in gojs

i have a diagram created with go.js library
and nodes are expandable with a custom button that have a plus as text
how can i update text of button on click event

You have several choices. Take a look at how the standard "…Button"s are defined in https://gojs.net/latest/extensions/Buttons.js.

“TreeExpanderButton” and “SubGraphExpanderButton” and “PanelExpanderButton” use Bindings to determine the Shape.figure or Shape.geometryString.

But you could modify it in a click event handler if you don’t want to use a Binding.