WAXML can give a report on the number of each element type in the configuration. It's only available through the [Javascript API] and it consists of only one getter: "statistics".
Ex: Read the statistical report from WAXML and display the result in the console.
Object.entries(waxml.statistics.elementCount).forEach(([nodeName, cnt]) => {
console.log(nodeName, cnt]);
});