In the previous chapters of the tutorial you've seen how to synchronize JSF bean attributes with the AngularJS model. However, you aren't limited to input field and html attributes.
To send an arbitrary JSF bean attribute to the client add the attribute "direction" to the <ngsync /> tag:
<ngsync value="{{grid.rows}} direction="serverToClient" />
AngularFaces uses Gson to convert beans into JSon objects. Sometimes this makes for clumsy data structures. For instance, the playground of the AngularTetris demo is a simple two-dimensional array of integers. However, I had to chose a much more complicated data structure because AngularJS had difficulties to access the cells in two nested ng-repeat directives. I suspect I did something wrong, but I also suppose that what feels a natural data structure in Java doesn't always result in a simple AngularJS model.
A particular nasty problem are arrays and hash maps. Because of Java's type erasure, there's no simple way to send a table back to the server. Everything's fine until the table grows at the client side. Gson doesn't know the type of the array, so it can't simply add rows to the table on the server side. That's the reason why I postponed two-way synchronization until AngularFaces 2.1.
That's a feature left for AngularFaces 2.1.
<ngsync value="{{grid.rows}} direction="clientToServer" />
Currently, the only way to send values back to the server are input fields. Of course you can add an <h:inputText> rendered invisible by CSS. The next request automatically sends values stored in the hidden field back to the server.
That's a feature left for AngularFaces 2.1. In the meantime the only work-around is using a hidden input field. I'll show you the sneak preview to the syntax anyways:
<ngsync value="{{grid.rows}} direction="both" />