4 ms·
Everyone should try to build their own pluggable framework at least once, to realize how difficult it is, and to realize how small design decisions can cause ma
by vaughan 5y ago
Everyone should try to build their own pluggable framework at least once, to realize how difficult it is, and to realize how small design decisions can cause massive headaches. I think a lot of frameworks are the result of someone shipping something, it gets popular, and then its stuck like that and they can't rethink it.
Having done this helps you to see things in new frameworks that will inevitably lead to pain.
As often as people deride it, the Node.js many-small-package philosophy (inspired by Unix) is what I keep coming back to. If one package doesn't provide the right abstraction to do something, if it's built on top of two smaller packages, I can assemble a new package with these smaller packages to achieve what I want. The smaller the package the better.
From the day the first line of code in a project is written, a desire to rewrite from scratch starts to grow - to return to the productivity of having an empty slate. If you compose your app from small single-purpose packages, rewriting becomes trivial.