4 ms·
I think the general rule of thumb (which I don't think the op adheres to): if your code calls it, it's a library, if it calls your code, (as in you are fulfilli
by dnautics 6y ago
I think the general rule of thumb (which I don't think the op adheres to): if your code calls it, it's a library, if it calls your code, (as in you are fulfilling some interface) it's a framework.
- naranha 6y ago...which makes the distinction even harder in node, because it is a callback based language. Nearly everything is based on my code being called. Sticking with the example of express.js, for me it feels more like a library since I'm still in control of the program flow, even though I need to adhere to certain interfaces.
- dnautics 6y agoWhy is the distinction harder? Node is a framework.
- undecisive 6y agoYeah. I'd also say if it significantly changes the way you code, it's a framework. So I wouldn't consider jQuery a framework, because you could replace any jQuery call with one or more lines of vanilla javascript. I would call react or backbone.js or angular etc frameworks, because you would have to completely restructure your codebase in most cases - or, at least, create compatible clones of those libraries.
- bckr 6y agoMost helpful comment of the day goes to...!