Frames for the YJ and TJ are different. Not huge differences,but enough so that it's not cost-effective to swap one into another. The XJ Dana 30 is a direct bolt-in to the TJ platform,and is a good swap as the TJ uses a low-pinion 30 whereas the (early) XJ uses a high pinion model. TJ owners look for the non-disconnect XJ axle to swap in and they generally will use their original axle shafts as they are of the 297-x variety and will swap directly into the XJ 30.