So yes, the transmission will bolt up. It may or may not hold up to it. Usually they don’t, but the one in my choptop has done fine. Of course, it’s probably a little lighter than stock and your Ranger so that may play into it. Run the larger 4.0 clutch.
Wiring will be your nightmare, everything on the drivers side will need spliced. You will need a wiring harness and computer ideally from a 90-92 Ranger with a manual transmission. You may be able to use a newer harness than that, but once they moved the computer to the cowl, then you get into more work. On the drivers side, the plugs are all different in the engine bay from 1988 and older to 1989 and newer and the 4.0 didn’t appear until 1990, so there’s no finding a matching harness. Think you also get into changing the starting/charging stuff. I started messing with it years ago with my 88 Bronco II, decided it was more than I really wanted to get into and didn’t need to do, so I used all that I collected to swap my 89 which was a much easier process and the 89 really needed it. That said, there’s more information on the swap now days.
There is a bunch of information in the tech archives (there’s a link at the top of the forums), and there’s also a bunch of stuff in the engine swaps forum.