In the previous chapter, Chapter 3, Magento 2 Theme Layout, we created the Hello World theme, but without any change in the CSS structure. Now that you've gained the knowledge of the use of the Magento UI library in your projects, it will be far simpler to understand the flow processes and the application of techniques in developing Magento 2 themes. Let's make some customizations in our Hello World theme using the Magento UI library:
Copy the file
<magento_root>/vendor/magento/theme-frontend-blank/web/css/_styles.less
topackt/app/design/frontend/Packt/compstore/web/css
.Open the copied file and insert an
import
command, as shown in the following example:@import 'source/lib/_lib.less'; @import 'source/_sources.less'; @import 'source/_components.less'; @import 'source/helloworld.less';
Save the file.
The _styles.less
file, besides being used as a standard nomenclature within the Magento 2 development environment, is also responsible...