Non-Button Display In ContextMenu

I have the following contextMenu defined for my diagram:

SeatingMapGraphicsRef.contextMenu =
$(go.Adornment, "Vertical",
  // no binding, always visible button:
  $("ContextMenuButton",
    $(go.TextBlock, "Hold Seats"),
    { click: function(e, obj) {
      holdSeatsInDragSelect();
    } }),
  $("ContextMenuButton",
    $(go.TextBlock, "Select Seats"),
    { click: function(e, obj) {
    } }),
  $("ContextMenuButton",
    $(go.TextBlock, "Lock Seats"),
    { click: function(e, obj) {
    } }),
  $("ContextMenuButton",
    $(go.TextBlock, "Cancel"),
    { click: function(e, obj) {
      var diagram = e.diagram;
      diagram.hideContextMenu();
    } })
);

I would like to define a GraphObject that isn’t a Button,
that displays within my context menu the following data:

myLocalArray.length() seats currently selected

where myLocalArray is within the scope of the contextMenu 's definition.
How do I go about doing that?

    nodeTemplate.contextMenu =
      $(go.Adornment, "Vertical",
          $(go.TextBlock,
            { stretch: go.GraphObject.Horizontal, background: "whitesmoke" },
            new go.Binding("text", "", function(obj) {
                             // obj is this contextMenu Adornment
                             return obj.diagram.selection.count + " selected";
                          }).ofObject()),
          $("ContextMenuButton", ...),
          . . .);

This shows in the context menu how many Parts are currently selected in the Diagram, updated each time the context menu is shown. Of course you might want to improve on the visual style.

Thank you! That is exactly what I was looking for.
I just have a couple questions about some things in your code:

Why do you pass "" as the second argument of the Binding class? Is it because we are converting a string into the text property of the TextBlock object?

And finally, in the conversion function, what is ofObject() doing there? Do you add it so it applies it to the TextBlock's GraphObject?

http://gojs.net/latest/intro/dataBinding.html discusses many aspects of data binding. http://gojs.net/latest/api/symbols/Binding.html provides additional details.