Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

After what point a JavaScript library is considered as a FrameWork? [closed]

I am kind of confused with the definitions.

Can you please define the minimum "must haves" of a JavaScript library so that it can be considered as a software framework?

thanks

like image 476
pencilCake Avatar asked Jan 21 '23 22:01

pencilCake


1 Answers

The distinction between a framework and a library is pretty fuzzy, in my opinion. Generally, software frameworks are larger-scale and usually "take over" your application (since they provide a basis, or "framework", for your application to be built upon). A library, on the other hand, just offers a collection of functions you can pick and choose from.

Wikipedia has some specific criteria for distinguishing frameworks from libraries as well:

  1. inversion of control - In a framework, unlike in libraries or normal user applications, the overall program's flow of control is not dictated by the caller, but by the framework.
  2. default behavior - A framework has a default behavior. This default behavior must actually be some useful behavior and not a series of no-ops.
  3. extensibility - A framework can be extended by the user usually by selective overriding or specialized by user code providing specific functionality.
  4. non-modifiable framework code - The framework code, in general, is not allowed to be modified. Users can extend the framework, but not modify its code.
like image 143
hbw Avatar answered Jan 24 '23 12:01

hbw