npm

dark-icon-generator
TypeScript icon, indicating that this package has built-in type declarations

1.0.3 • Public • Published

Dark Icon Generator

Dark Icon Generator is a tool to convert light icons to dark icons using Node.js. Works quite like Apple's iOS 18 dark app icons.

Example

Installation

You can install the package using npm or yarn:

npm install dark-icon-generator
yarn add dark-icon-generator

Usage

To convert a light icon to a dark icon, you can use the convertDarkIcon function:

import { convertDarkIcon } from 'dark-icon-generator';
import * as fs from 'fs';

async function convertIcon() {
    const iconPath = 'path/to/light/icon.png';
    const icon = fs.readFileSync(iconPath);
    const darkIcon = await convertDarkIcon(icon);
    fs.writeFileSync('path/to/dark/icon.png', darkIcon);
}

convertIcon();

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
1.0.31latest

Version History

VersionDownloads (Last 7 Days)Published
1.0.31
1.0.12

Package Sidebar

Install

npm i dark-icon-generator

Weekly Downloads

3

Version

1.0.3

License

MIT

Unpacked Size

14.1 kB

Total Files

5

Last publish

Collaborators

  • agou