think of any type of software project, it's just a lot of functions calling to each other, getting that to scale without becoming a mess was really hard to me, so what I did was that I started to try different architectural patterns to see what worked for me, my current coding style is a mix of 1) functional programming, 2) hexagonal architecture, and 3) test driven development; and I found that object oriented programming is not good at all it causes plenty of problems as the codebase grows, I mention OOP because is one of the most mentioned ones but I think is not that good.
I develop in TypeScript, so I use the library Effect plenty of it follows functional programming principles, it also has dependency inyection with the objects Context and Layer which can be used for hexagonal architecture and for test driven development I use vitest