Creating a child theme structure
Let’s create our first child theme by following the present recipe:
- The first thing before creating a child theme is to make sure that we have the technical name (folder name) of the original theme we want to use. As a practical example, we will work on the classic theme located in the
/themes/classic/
folder. Its technical name isclassic
. We will create a child theme of theclassic
theme, which we decided to namechildclassicwh
. So, let’s create the/themes/childclassicwh/
folder to store our child theme files. - The only mandatory files needed are the
/themes/childclassicwh/config/theme.yml
file to define the metadata necessary to describe our child theme, and the/themes/childclassicwh/preview.png
file containing the thumb displayed on the theme’s installation and settings BO pages. - Let’s focus on the
/themes/childclassicwh/config/theme.yml
file first and see how to create it. Its mandatory properties will...