No description
Find a file
2025-07-12 23:26:58 +12:00
src 1.1.0 2024-10-06 14:14:08 +13:00
test update deps 2025-07-12 23:25:30 +12:00
.gitignore update deps 2025-07-12 23:25:30 +12:00
eslint.config.js update deps 2025-07-12 23:25:30 +12:00
LICENSE Initial commit 2024-10-05 03:21:25 -07:00
package.json v1.3.0 2025-07-12 23:26:58 +12:00
pnpm-lock.yaml update deps 2025-07-12 23:25:30 +12:00
README.md update deps 2025-07-12 23:25:30 +12:00
tsconfig.json v1.0.0 2024-10-06 00:14:05 +13:00

sharp-read-bmp

Function for reading bmp and ico and returning a sharp instance

Installation

npm install @valkyrie-dev/sharp-read-bmp

Usage

import { sharpBmp } from '@valkyrie-dev/sharp-read-bmp';
import { fileTypeFromFile } from 'file-type';

const { mime } = await fileTypeFromFile('favicon.ico');
const sharpCtx = await sharpBmp('favicon.ico', mime);

console.log(await sharpCtx.metadata());