file-signature

1.0.0 • Public • Published

file-signature Build Status

Get file information based on file signature. This utility is used to get file information based on the file signature. It does so by looking at "magic numbers" common formats contain.

Data for this script was generated from: http://en.wikipedia.org/wiki/List_of_file_signatures

Example use:

 
var fileSignature = require('file-signature');
console.log(fileSignature.identify('path/to/file.jpg'));
 
// outputs:
// {
//   extension: 'jpg',
//   description: 'A commonly used method of lossy compression for digital photography (image).',
//   mimeType: 'image/jpg'
// }

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.0
    98
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.0
    98
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i file-signature

Weekly Downloads

81

Version

1.0.0

License

ISC

Last publish

Collaborators

  • leahcimic