Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pfrazee/identify-filetype
Identifies the file-type of a buffer
https://github.com/pfrazee/identify-filetype
Last synced: 2 months ago
JSON representation
Identifies the file-type of a buffer
- Host: GitHub
- URL: https://github.com/pfrazee/identify-filetype
- Owner: pfrazee
- Created: 2016-06-04T19:05:05.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2016-06-04T19:05:25.000Z (over 8 years ago)
- Last Synced: 2024-10-17T17:37:07.840Z (2 months ago)
- Language: JavaScript
- Size: 1.95 KB
- Stars: 11
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# identify-filetype
Identifies the file-type of a buffer using the [magic-number signatures at the start of the file](http://en.wikipedia.org/wiki/list_of_file_signatures).
```js
var identify = require('identify-filetype')console.log(identify(some_buffer)) // => string | false
```**Supported types:**
jpg
png
gif
bmp
tif
tif
nif
ico
psd
rar
zip
gz
msi
iso
rtf
avi
wmv
wma
swf
flv
mid
doc
docx
mp3
svg
html**Tested:**
tif
psd
gif
jpg
png
bmp
tif
ico
rar
docx
gz
doc
rtf
svg
html