No, if there is a vanilla API way to do so, this is beyond my knowledge and ability.
This is automatic for pole type entity, but takes lots effort to add for other types.
It has to be done by keep tracking of every poles and make rendering rectangles for each of them. I do not have such time to spend on this. Not to say it is potentially performance killing, as bases usually have thousands of poles.
This is no difference from showing power network grid when user is holding any specific type of items in cursor.
You can request this feature in Factorio forum, see if anyone have the time to spare on this.