In most cases you would want to place a large capacitor closest to the point that will potentially need the high current. If you are enabling the motor with a pull to ground (Low Side Driver) the cap should be from the motor + point to ground. If you enable the motor with a driver on the + line (High Side Driver) you would place the cap just ahead of the driver supply line.
With the cap in place and before the motor starts the large cap becomes fully charged. When the motor is enabled the initial high current will be supplied mainly from the cap and not the longer length supply line. Because this initial high current comes from the cap there is less of a spike seen on the supply line.
If no cap is used, or if the cap is only near the power supply point, the small resistance and inductance of the trace might become significant when there is a fast high current drain needed by the motor. This current spike could affect other circuits that are on the same supply line. Even if there are no other circuits on the line the motor will respond faster with the nearby cap because the high current will be available faster. In some cases your power supply may not be able to supply the high current pulse and this could cause a spike on the line.
simulate this circuit – Schematic created using CircuitLab