Doing a quick test to see if I can use this with https://github.com/Automattic/cli-table ...
const terminalImage = require('terminal-image');
const Table = require('cli-table');
(async () => {
const img = await terminalImage.file(process.argv[2], {width: 50, height: 50});
const table = new Table({head: ['img', 'caption']});
table.push([img, 'description #1'], [img, 'description #2']);
console.log(table.toString());
})();
It works nicely in macOS native terminal:
But in iTerm 2 I'm getting a screen full of lines, like the table thinks the output is (much) larger than it is. Customizing row widths in cli-table doesn't seem to help. Any idea if this is something I could reasonably expect to work, or just incompatible with whatever special image rendering iTerm 2 has? Maybe related to #29? Thanks!
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too