React-scripts V5 clashes with WEB3

I know this has been asked in a similar post here which has been solved and its not a moralis isssue moreover its a web3 and react issue. react-scripts v5 seems to not work with web3.js funnily enough i had not even noticed myslef until i inited a new react app the other day which uses v5 react scripts and web3 would not work at all kept getting lodes of crazy errors to do with polyfills and the likes for a while i was like what the hell why is my other reeact project running fine nd this one doesnt and now in hindsight obviosully its to to with the new version update. I know you can just change your react scripts version but what i want to know is what is it it that makes it clash with v5 react-scripts and is there a workaround for furture so that one doesnt have to constantly depend on react scripts version below v5. cos there seems to be a lot of big yucky errors that between web3 and react-scriptsv5.