Open GantMan opened 6 years ago
This works as long as the width of each column is >=3 characters.
table(data, {
border: {
topBody: '',
topJoin: '',
topLeft: '',
topRight: '',
bottomBody: '',
bottomJoin: '',
bottomLeft: '',
bottomRight: '',
bodyLeft: '|',
bodyRight: '|',
bodyJoin: '|',
joinBody: '-',
joinLeft: '|',
joinRight: '|',
joinJoin: '|'
},
drawHorizontalLine: (index) => index === 1
})
Shame I can't combine the drawHorizontalLine, I could do the PR to add the template.
Maybe it should return a full config that can be extended? Thoughts? Not sure how to take it from here.
Great existing table templates, but one key item that's missing is the Markdown table.
Results in cool stuff on github, like so:
Would be nice if we could give users a copy/paste friendly table for github!
https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#tables