Nope, the frame and front sheet metal are different between the '97 and earlier Rangers and the '98 and newer ones so the kits for the pre-98's won't work.
Mounting the engine and transmission from a '96 - '01 5.0 Explorer or Mountaineer is the easy bit. Essentially bolt in if you've got the torsion bar front suspension, only needs some custom mounting plates if you've got the coil spring suspension.
The challenge will be with the electrics -- the 2010 dash and emissions system won't work with the much earlier 5.0. The later dash uses CANBUS data, the earlier uses raw data from the PCM or engine sensors.
Common wisdom has it that the only practical solution is to re-wire the Ranger to use an earlier instrument cluster and swap in the evap valves.
But, there are starting to be "Translators" on the market that will take earlier data and convert to a more modern format.
The later 4.6/5.4 or Coyote engines are all but physically too big to fit without significant modifications and fab work but would solve at least some of the electrical issues.
No easy answer to do such a swap, but that does not make it impossible.