xlsx-template
xlsx-template copied to clipboard
Dynamic Nested Header Support
Hello,
First of all, this is super helpful library. Thank you for your support. Anyway, I am wondering that how can I do dynamic headers(nested dynamic headers)?
For instance,
var values = {
items: [{
name: 'Drink',
count: 3,
brand: 'Pepsi'
}, {
name: 'Food',
count: 2,
brand: 'KFC'
}, {
name: 'Desert',
count: 5,
brand: 'CheeseCakeFactory'
}]
}
and I want to print this array in this format:
Drink count 3 brand Pepsi
Food count 2 brand KFC
Desert count 5, brand CheesecakeFactory
I thought this way, but it did not work out:
${table:items.name}
${table:items.count}
${table:items.brand}
but it prints
Drink Food Desert 3 2 5 Pepsi KFC CheesecakeFactory
if this lib supports this feature, please let me know how can I do that? Thanks a lot for any kind of help!
+1