It would depend on if you're extending the stepper motor wiring, or the control signals to the motor.

To the drive, you might get some lost/additional steps, but I'm going to guess you don't need that precise a position, so probably won't be that much of a problem.
To the motor, worst issue would potentially be the stepper wiring causing noise in the opto sensor, causing false triggers when you're trying to home, however a bit extra load on the opto with a suitable resistor would soon solve that.