Not eating vast quantities of sugar is good advice, but it's not the direct cause of T2 diabetes. The best evidence suggests that T2 diabetes is caused by the accumulation of fat in the liver and pancreas. See the twin cycle hypothesis. To prevent diabetes, one needs to maintain a weight low enough where the body isn't storing fat in the liver and pancreas (everyone has their own individual threshold for this). If you're pre-diabetic, lose enough weight and most people will regain insulin sensitivity.
This can help sustain a high level of exercise (the more the better). Certainly don't if you're sedentary, but the sugar during exercise is really helpful for getting in 10+ hours/week of exercise.
https://link.springer.com/article/10.1007/s13668-026-00740-w
> habitually drinking... sugar-sweetened-beverages
Yes, terrible idea, avoid!