Although still in the development phase, Magento 2.0 comes with a distinctive set of changed/improved approaches compared to its predecessor Magento 1. There are significant changes/improvements to overall layout manipulation, file structure and a brand new introduction to Magento UI library heavily based on LESS preprocessor with built-in compiler. Let’s take a look at some of the most exciting changes you can look forward to.
Read more on this topic: Web development trends 2017
Frontend architecture changes
The big difference is that frontend is now updated with newer technologies such as HTML5, CSS3. Another big change is the removal of the skin directory. Everything is organised directly under the app structure. Every module has its own VIEW directory where all module-specific template, layout, js, and CSS/fewer files are stored.
Read more: Web designer vs front end developer
This is a better approach and certainly, it will be beneficial for module developers. All visual content will be stored directly within the module separating it from Magento core. It means that the structure inside app/design/frontend/vendorName/newTheme/ is no longer divided into layout and template directories. Instead, we need to include the module directory and its complete hierarchy to override the default directory structure.
Simplified Config with valid XML
If you’ve ever created a module or used Magento as a developer, you would’ve experienced the large learning curve associated with it. This learning curve is mainly due to the amount of configuration that is able to be set within Magento modules. In Magento 1.0 you set everything in configuration, including the folder structure, database connection, admin menus, access control, entities, installation resources, the list goes on for a while, so I won’t list is all here. Although it provides a lot of functionality, you do end up writing a lot of boilerplate configuration.
In version 2.0, they have removed the module activation file (normally found in app/etc/modules/) and combined it into the module’s config XML. Fewer files are better. They have also removed the functionality to set the folder structure for blocks, models and helpers, which is nice since we do not really need to set these to something different.
- Read more: Top 7 In-Demand Programming Languages 2019
In the video, they were saying that on average it’s 20% less code. And that they’re making this a valid XML file. The new structure of the module directory will enable faster and logical development of the platform infrastructure. Finally, we can validate the file against an XML schema, without wasting hours of frustrating diagnostics.
The new concept of containers
One of the great and more than welcome changes is an introduction of a container wrapper, the successor to a core/text_list block type which served the role of a structural block in the previous versions of the system. What is really interesting is a possibility to pass attributes like htmlTag, HTML class, htmlId directly from layout files.
The introduction of bootstrapping entry point code
A feature that I think is well overdue. Global entry point code or Bootstrapping code enables different parts of Magento to act as one. The idea is that no matter if you’re running the cron.php or you’ve got a symlink multistore setup, booting all runs through the same code. This enables a store to be disabled on the front end, can, and any XML-RPC or soap services to be disabled as well. Again, well overdue. This isn’t particularly revolutionary but it’s worth noting as a major feature add.
The removing of several core modules
Admin-HTML is no more. Ever since the controller override functionality that was introduced quite a few versions ago now, the Adminhtml module has been legacy code that’s stuck around, and because of the timeframe that Magento has put on the rollout of version 2, we’re seeing lots of code changes, the old payments methods and compiler are replaced with new and advanced payment options. They’ve made it clear that they’re expecting the community to create extensions to replace this functionality and that it won’t be in the core code.
Other changes that we may discuss later
– Magento 2.0 will use Zend Framework 2 for managing performances of cache engine, database access layer and translations. – jQuery replaced Prototype. – Ability to change product attribute set. – Drag and drop product images in
– jQuery replaced Prototype.
– Ability to change product attribute set.
– Drag and drop product images in the admin panel.
– Improved multilingual support.
Development on Magento 2.0 right now
Unfortunately, a release date for Magento 2.0 has not been announced yet. Right now, if you’re a developer, you can find it on git hub (https://github.com/magento/magento2) and the Magento team have said that they are open to git pull requests. They’ve even been nice about the tools they’re creating to assist in the transfer, so fingers crossed it won’t be as bad as we think, but only time will tell.