In this code, the new SubSupText is being assigned to valueLabel at the same time as it is added into the children array. My recommendation is to avoid this pattern in PhET code as it is harder to read and maintain.
If there are other places in the code that use this pattern, it would be good to change those as well. Thanks.
During code review #56, I noticed this code in GravityWithSliderListNode:
In this code, the new SubSupText is being assigned to valueLabel at the same time as it is added into the children array. My recommendation is to avoid this pattern in PhET code as it is harder to read and maintain.
If there are other places in the code that use this pattern, it would be good to change those as well. Thanks.