This can be avoided by toggling "Enable Steam Input for Switch Pro controllers" from Steam > Settings > Controller.