Areas

  

  

Magento areas. Magento uses areas to loading only the dependent code for the specified area.And area organizes the code for optimized request processing.Each of the default areas can contain completely different code on how to process URLs and requests. For example:If you need to perform a REST API call rather than load all the code related to generated user HTML pages or something like that, you can specify separate area that loads code whose scope is limited to answering only rest API calls. Magento is organized into these main areas:"ADMIN HTML" - the admin panel area includes the code needed for the admin panel. "Frontend" contains template and layout files that defines the appearance of your storefront. "Base" used as a fallback for the files absent in "ADMIN HTML" or "frontend" areas.And actually can be used for the common functionality of these areas."Crontab" which entry point in "pub ... cron.php" file and this area is for CRON tasks.You can also send requests to Magento using SOAP API and REST API.And now even via GraphQL.So each of these API has its own area.Modules define which resources are visible and accessible in particular area.So let's take a look on some examples.For example:vendormagentomodulecatalog and the folder for configurations, etc..Let's say."di.xml" file ... as you can see, we can define it on global level as well as on frontend or only for "ADMIN HTML" area.And also, we have this configuration for REST API and the same for "SOAP".So that's actually how it works!
You have completed 0% of the lesson
0%