This is the cleanest way I have found to mount limit switches for the new auto squaring firmware.
https://www.v1engineering.com/
Details here, https://www.v1engineering.com/auto-square-dual-endstops/
You will need 4 stop blocks and roller plates, 2 of each.
Of course get the right size plate for your build.
C=23.5mm
J=25.4mm
F=25mm