I'm not a professional but it's depends too the social media (like scrapping Instagram it's not the same to scrapping X).
Also social media fighting Instagram (blocking if to many requests are made) and they change their HTML tags.
But like I said I'm not a professional in scrapping and I can make some mistakes.