logoalt Hacker News

socketcluster • today at 12:24 AM • 0 replies • view on HN

I think one of the most profound changes I've observed on the tech side is the definition of 'modularity'; in the past, ideal modularity implied that the code could be locked down to a specific version, packaged up, distributed and everyone would integrate it into their projects as-is; everyone's projects would use the same module. This is a double-edged sword. If the module is secure and efficient, then that means everyone benefits from the security and efficiency, otherwise it means everyone is vulnerable to the same flaws or everyone suffers from the same inefficiencies.

In our new reality, module distribution has changed. We no longer need to obtain a module as-is from npm or whatever package manager... We can just get AI to pull it from another repo and make any necessary adaptations. The AI becomes the new npm and it's not a straight copy. Modules are more like blueprints rather than ready-made parts.

That said, modules still benefit from having simple interfaces, high cohesion, loose coupling. The ideal code doesn't look any different than before, it's just that the ideal distribution mechanism for it has changed. The design of the module significantly influences the logic surrounding it and that's why code quality still matters.