Ordering ui tree json so that arrays come last for easier reading