How to create themes in magento 2.
Magento is an e-commerce framework built using php, based on symphony framework. With the support for Magento 1.x coming to and end by June 30, 2020.
A theme is a component of Magento application which provides a consistent look and feel for entire application area.
Often you find yourself working with templates, layouts and stylesheets. Magento come with two default themes called blank and luma.
Create a new theme which is not luma or blank.
Create a directory for the theme under
Add a declaration file theme.xml and optionally create etc directory and create a file named view.xml to the theme directory.
Add a composer.json file.
Let's look into the theme.xml file
Your newly created theme extends blank theme, which has all necessary styles required for any theme development. However if yout store is being developed from scratch, it's good to use blank as parent theme instead of luma as you would be overriding the existing styles to suite your store.
You can start applying styles based on modules or entire theme level using the
_theme.less files. However if you want to extend the parent styles and additional styles, you can use
You can check Magento's ui library for available less variables and mixins, which is available in
lib folder in your Magento root directory, the library also comes with a guide.
Originally Published on Dev.to