Get associated file icon for Node.js.
To install this package, just run
$ npm install extract-file-icon
The following example shows how to get the currently focused window's title and hide it.
const fileIcon = require("extract-file-icon");
const icon = fileIcon('path', 32); // Returns PNG buffer of 32x32 file icon at given path.
path
stringsize
number - by default its value is 64. On Windows it can be only 16, 32, 64 or 256.