Dies ist eine alte Version des Dokuments!


LU04a - Framework vs. Library

  1. Definition what a software library is
  2. Definition what a framework is
  3. Names the differences of both

Libraries and frameworks streamline software development by providing reusable code and predefined structures. Libraries focus on specific tasks, enabling modularity, while frameworks establish an overall application architecture, promoting consistency. The choice between them depends on project needs and desired flexibility. Together, they reduce development time, enhance quality, and simplify the integration of advanced features across various platforms.

First, however, it is important to distinguish between the terms. “Library” and ‘framework’ are often used interchangeably - which, strictly speaking, is wrong. Even if the transition is indeed fluid in many respects, there are fundamental differences between the two.

A software library is a collection of pre-written, reusable code that provides specific functionality for developers. Libraries simplify programming tasks by offering modules or functions for common operations, such as handling data, managing files, or creating user interfaces. Unlike frameworks, libraries are less prescriptive, allowing developers to call and integrate them as needed without imposing strict design patterns.

A framework is a structured platform or foundation for developing applications, offering pre-written code, tools, and guidelines to streamline the process. It provides a standardized way to build and deploy software, saving time and ensuring consistency. Frameworks support specific languages or domains, such as web development (Django, Angular) or data analysis (TensorFlow), enabling efficient and organized coding practices.

 Who-calls-who diagram

Libraries and frameworks are tools that simplify software development by providing pre-written code. Libraries offer reusable functions for specific tasks, giving developers control over when and how to use them. Frameworks, on the other hand, define a structured architecture, requiring developers to work within their rules. The „who-calls-who“ distinction highlights that in libraries, the developer calls the library, while in frameworks, the framework calls the developer’s code.

Library Framewor
Library is a set of reusable functions used by computer programs. Framework is a piece of code that dictates the architecture of your project and aids in programs.
You are in full control when you call a method from a library, and the control is then returned. The code never calls into a framework; instead, the framework calls you.
It’s incorporated seamlessly into existing projects to add functionality that you can access using an API. It cannot be seamlessly incorporated into an existing project. Instead, it can be used when a new project is started.
They are important in program linking and binding process. They provide a standard way to build and deploy applications.
Example: jQuery is a JavaScript library that simplifies DOM manipulation. Example: AngularJS is a JavaScript-based framework for dynamic web applications.

You will find a list with JavaScript-Libraries und Frameworks including an explaination and a rathing as follows: here .

  • en/modul/m291/learningunits/lu04/theorie/01.1737457217.txt.gz
  • Zuletzt geändert: 2025/01/21 12:00
  • von vdemir