Bill Of Materials : Variants

Hello
In the same way a template is used to create a variant, is it possible to have a Bill of Materials Template that is used to create the bill of materials for variants?
For example, i make shoes with variation in sizes. The materials are all the same except for lengths of leather and size of the sole. How do i do this in ERPNext?

We had this use case a while back for a customer from Garment/Apparel Manufacturing and our blog here has more information on this, maybe some of it could be useful to you.