Yeah derailleur is fitted correct and chain should be sized right – max compressed travel is longest and then follow my usual method (not through derailleur, big sprocket, + 2 links).
Repeating it with the suspension unsagged needs about 4 links less.
Using a GS RD that’s (42-10)=32T + say 4 teeth for chain growth = 36T which is just within the 39T of the GS so should be okay and manually setting the RD to 10T and 42T it just copes and should be just okay if i switch down to a 30T chainring from the 32T without shortening the chain.
Also have an SGS RD here which looks a lot better in term of angles but looks much more vulnerable due to the extra 20mm. SLX GS is 5mm longer than XT which gives a 41T capacity (SGS XT 47T)
Set at 6mm the GS jut clears the swing arm pivot in the 10T with the suspension at max height. I guess it will never really be in that position with a rider on it.