Is there a simple built-in way to output formatted data to console in Node.js?
Indent, align field to left or right, add leading zeros?
If you have simpler needs you can look into util.format. It can generate string from various parameters. If you want printf like formatting you can use either sprintf package or sprintf-js package.