Perhaps because US government wanted to do it despite TikTok not breaking any serious provisions of law this law has been made.
It feels like a sleight of hand from government to ban something that has broke no (serious) law (yet).
Did the SCOTUS go into the necessity of having this law to achieve what government wanted, if existing laws would have sufficed, provided that government met the standards of evidence/proof that those laws demanded.
If not, it is as if government wanted a 'short-cut' to a TikTok ban and SCOTUS approved it, rather than asking government to go the long way to it.