gitbrent/xlsx-js-style

Auto width

Opened this issue · 1 comments

Hi! Firstly, thanks for this library!

One cool feature that could be added is the ability to adjust the cell width to the text. I'd be willing to do it if you could explain a little bit about where I could start.

You can set the col width like this

var wscols = [
    {wch:6},
    {wch:7},
    {wch:10},
    {wch:20}
];

ws['!cols'] = wscols;