1.0.1 • Published 5 years ago

electron-ext-icon v1.0.1

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

electron-ext-icon

NPM

Get icon associated with file extension.

Installing

$ npm install electron-ext-icon

API

  • getExtIcon(ext: string, options?: Electron.FileIconOptions): Promise<Electron.NativeImage>
// Electron main
import { writeFileSync } from 'fs';
import { getExtIcon } from 'electron-ext-icon';

const icon = await getExtIcon('html', { size: 'normal' });

icon.toDataURL(); // Base64

Related

  • Qusly - An FTP/SFTP client with Material Design UI.