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

2.0.1 • Public • Published

Mime2Ext

Convert a mime type to a file extension. It works only with popular mime types and it's super lightweight.

This library is designed to only support the ~300 popular mime types listed here.

Install

npm install mime2ext

Usage

import mime2ext from 'mime2ext';

// Let's convert a mime type to a file extension

mime2ext ( 'audio/mp3' ); // => 'mp3'

License

MIT © Fabio Spampinato

/mime2ext/

    Package Sidebar

    Install

    npm i mime2ext

    Weekly Downloads

    806

    Version

    2.0.1

    License

    MIT

    Unpacked Size

    2.76 kB

    Total Files

    5

    Last publish

    Collaborators

    • fabiospampinato