This is less about open source, and more about how people consume it. If you take open source as simply one of many available resources, read the code, and make deliberate decisions whether to use it, fork it, modify it, etc, then actively engage with its presence in your codebase, you are fine. On the other hand, if you "npm install <whatever>" as the easy answer to every question, you will get burned: At best by code bloat, at worst by malicious actors.