For the transponder, yes, keep it short.
For the com, not so important.
It all has to do with how lossy the coax is, high frequencies being more lossy. DME, ADSB, gps are all ‘high frequency’.
Of course there are exceptions, like the Garmin gps units (high frequency) that require some minimum loss.