arquero
arquero copied to clipboard
added class and classAlt options
Additional properties for adding class name attribute to the HTML tag names generated by .to-html
formatter Optionally, a classAlt
key can be used for tying a different class to every other tag rendered. Perhaps this method could replace the inline style properties.
Example with different Bulma class name alternating per row:
table(data)
.toHTML({
class: { tr: "has-background-white-bis", td: "p-1"},
classAlt: {tr:"has-background-light" },
limit: 10
})
I haven't tested the function passing, although I used the same logic as the style
tag , so should work the same way.