Good typography reinforces the goals of the text.
Almost all texts communicate a set of points (Summary judgment should be denied for three reasons). Sometimes a text also needs to instruct the reader (Add lines 7 through 21 and enter the total here). Other texts offer warnings or admonitions (You must be 48 inches tall to ride; Speed limit 75). In every case, good typography supports and reinforces the message.
Good typography is measured on a utilitarian yardstick. Typography that is aesthetically pleasant, but that doesn’t reinforce the goals of the text, is a failure. Typography that reinforces the goals of the text, even if aesthetically unpleasant, is a success.
Does that mean that effective typography can be ugly? Sure. Sometimes ugly is better than pretty. Look at the highway signs again.
The script font used on the second sign could be called “prettier” than the standard highway-signage font. But a highway sign has a special purpose: it’s meant to be read quickly, from long distances, at odd angles, and under variable lighting and weather conditions. The highway-signage font stays legible under all these conditions. It constitutes good typography because it supports the goals of the sign.
The script font may be prettier, but in this context, it’s bad typography, because it’s not suited to the task. Conversely, the highway-signage font would look terrible on a wedding invitation, where the script font would be appropriate.