NFPA79 states you need to remove all motive power in case of an E-stop. Fitting a e-stop contactor on the input can still follow regs by installing a "controlled stop" , fortunately NFPA allows you to read the motor stop condition before removing the power, (controlled stop) in this case you will not experience any problem.

It can be done by setting one of the VFD outputs to 'At Zero Speed' in order to keep the VFD contactor in until zero speed, this allows the required delay before operating the VFD E-stop contactor.
The normal instant e-stop relay would first operate the stop PLC input on the VFD, it sounds a little complicated, but simple once you work on it.
As a CNC retro-fitter, I am obliged to follow the rules and observe safety, and this works well for me!
Al.