Specifications
What WooCommerce shows under «Additional information»: weight, dimensions and
every attribute the shop marked «visible on the product page». A page built from
components never renders that tab, so the list comes as data instead —
{this.fecommerce.attributes}, in WooCommerce's own order — and an Etch loop
draws it however the shop wants. If the loop's item is called row:
| Field | Example |
|---|---|
{row.label} | Colour · Weight · Dimensions |
{row.text} | Blue, Green, Red — every value in one line, which is what a cell usually wants |
{row.values} | The values one by one, for a loop inside the loop: {value.name} and {value.url}, which is the attribute's archive where the shop has one |
Wrap the section in a condition on {this.fecommerce.attributes}: plenty of
products have nothing to say here, and an empty «Specifications» heading says
less than none.
Only worked out for the product being viewed — reading an attribute's terms is a query each, and no card shows a specification.