GitHub – RocktimSaikia/mime-type-check: Get MIME type of a file by its extension

Get MIME type of a file by its extension

Files

Permalink

Failed to load latest commit information.

Type

Name

Latest commit message

Commit time

Get MIME type of a file by it’s extension

Install

npm install mime-type-check

Usage

const getMimeType = require('mime-type-check');

getMimeType('./images/profile.svg');
//=> 'image/svg+xml'

getMimeType('https://rocktim.xyz/images/profile.svg');
//=> 'image/svg+xml'

API

getMimeType(string)

Get MIME type of a file by it’s extension

Support

About

Get MIME type of a file by its extension

Topics

Resources

License


You can’t perform that action at this time.



Source link