Home
+91 80976 50735
info@appmonks.net
×

Magento Framework

The Magento Framework controls how application components interact, including request flow, routing, indexing, caching, and exception handling. It provides services that reduce the effort of creating modules that contain business logic, contributing to the goal of both making Magento code more modular as well as decreasing dependencies.This primarily PHP software component is organized into logical groups called libraries, which all modules can call.

Responsibilities

The Magento framework provides libraries that help reduce the effort of creating modules that contain business logic. The framework is responsible for operations that are useful for potentially all modules, including:

• handling HTTP protocols.

• interacting with the database and filesystem.

• rendering content.

Magento Components:

Magento has several core components that are used to build custom web sites, applications, and integrated systems. When you change the appearance or behavior of your Magento store, you are inevitably changing one or more of these core Magento components, which include modules, themes, and language packages. Together, these core components determine much of server-side and storefront (frontend) appearance and behavior.

1. Module: 

A module is a logical group – that is, a directory containing blocks, controllers, helpers, models – that are related to a specific business feature. In keeping with Magento’s commitment to optimal modularity, a module encapsulates one feature and has minimal dependencies on other modules. The Magento Framework provides a set of core logic: PHP code, libraries, and the basic functions that are inherited by the modules and other components. A module is a directory that contains the PHP and XML files (blocks, controllers, helpers, models) that are related to a specific business feature, such as Shipping. Specifically, a Magento module is composed of these software components: themes, libraries, and language packages.

 2. Theme: 

A theme is a core Magento component whose primary purpose is to control the appearance of your storefront. Themes use a combination of application elements, such as templates, layouts, styles, and images, and are highly extensible. Custom theme development is one of two main methods of modifying Magento behavior and storefront appearance (extending modules is the other primary way, and the main way to tailor Magento behavior). Themes are the primary way to customize your Magento storefront appearance. Unlike modules, themes do not provide new business features. Themes within a Magento installation relate to each other through inheritance, allowing you to customize an existing theme by defining it as a parent theme whose settings can be inherited by any designated child themes.

3. Language packages: 

Any text that is presented to the user can have several captions or labels on the control elements, notifications, and error messages. Creating a language package is part of the process of localizing your storefront. A Magento language package is a collection of translation dictionaries for a particular language together with additional information that tells Magento how to process the information, including:

• .csv file contains the actual strings that comprise the language dictionary. A translation dictionary is a comma-separated value (.csv) file with at least two columns: the original phrase in the en_USlocale and a translation of that phrase to another locale.

• composer.json file contains any dependencies for the language package and a mapping to its defined locale.

• language.xml file, where you declare a language package and establish any inheritance rules, if you are installing multiple language packages.

Magento libraries:

Magento uses the following types of libraries:

1. Magento PHP libraries: Magento PHP libraries include independent libraries of code useful to a Magento application. Each library has minimal dependencies on other library.

• Magento\Framework\Filesystem has PHP libraries for file system operations such as read, write, and directory listing. We provide drivers for file, HTTP, HTTPS, and Zlib.

• Magento\Framework\App is a special PHP library that is aware of Magento as an application. It represents a greater level of abstraction and provides Application areas, Routing requests, Application state.

2. Magento UI libraries: The Magento UI library is a flexible modular Magento frontend library that is designed to assist Magento theme developers. It employs a set of mixins for base elements to ease frontend theme development and customization.

The Magento UI library offers the following characteristics:

• Built on LESS preprocessor

• Focused on web standards

• Customizable

• Easy to maintain

• Responsive

• Accessible

3. Third-party libraries: Magento depends on a set of external libraries. You can use Composer to manage these dependencies. Composer downloads all of the external libraries that are included in its main configuration file and installs them under its default installation directory (vendor/). Third-party libraries include the Zend framework files and the Symfony libraries. There are some required libraries that Composer does not load. These reside in lib/ and include JavaScript libraries (none of which are loaded by Composer) and a few PHP libraries. (You can also use Composer to manage dependencies between various components within Magento.)



Mail