Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

file-type

Package Overview
Dependencies
Maintainers
2
Versions
150
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

file-type - npm Package Compare versions

Comparing version 13.0.3 to 13.1.0

10

core.d.ts

@@ -127,3 +127,6 @@ /// <reference types="node"/>

| 'aac'
| 'mp1';
| 'mp1'
| 'it'
| 's3m'
| 'xm';

@@ -243,3 +246,6 @@ type MimeType =

| 'application/x-esri-shape'
| 'audio/aac';
| 'audio/aac'
| 'audio/x-it'
| 'audio/x-s3m'
| 'audio/x-xm';

@@ -246,0 +252,0 @@ interface FileTypeResult {

@@ -758,2 +758,9 @@ 'use strict';

if (checkString('IMPM')) {
return {
ext: 'it',
mime: 'audio/x-it'
};
}
// -- 6-byte signatures --

@@ -1054,2 +1061,9 @@

if (checkString('Extended Module:')) {
return {
ext: 'xm',
mime: 'audio/x-xm'
};
}
if (checkString('Creative Voice File')) {

@@ -1086,2 +1100,9 @@ return {

if (checkString('SCRM', {offset: 44})) {
return {
ext: 's3m',
mime: 'audio/x-s3m'
};
}
if (check([0x47], {offset: 4}) && (check([0x47], {offset: 192}) || check([0x47], {offset: 196}))) {

@@ -1088,0 +1109,0 @@ return {

7

package.json
{
"name": "file-type",
"version": "13.0.3",
"version": "13.1.0",
"description": "Detect the file type of a Buffer/Uint8Array/ArrayBuffer",

@@ -168,3 +168,6 @@ "license": "MIT",

"aac",
"mp1"
"mp1",
"it",
"s3m",
"xm"
],

@@ -171,0 +174,0 @@ "devDependencies": {

@@ -377,7 +377,17 @@ # file-type [![Build Status](https://travis-ci.org/sindresorhus/file-type.svg?branch=master)](https://travis-ci.org/sindresorhus/file-type)

- [`aac`](https://en.wikipedia.org/wiki/Advanced_Audio_Coding) - Advanced Audio Coding
- [`it`](https://wiki.openmpt.org/Manual:_Module_formats#The_Impulse_Tracker_format_.28.it.29) - Audio module format: Impulse Tracker
- [`s3m`](https://wiki.openmpt.org/Manual:_Module_formats#The_ScreamTracker_3_format_.28.s3m.29) - Audio module format: ScreamTracker 3
- [`xm`](https://wiki.openmpt.org/Manual:_Module_formats#The_FastTracker_2_format_.28.xm.29) - Audio module format: FastTracker 2
*SVG isn't included as it requires the whole file to be read, but you can get it [here](https://github.com/sindresorhus/is-svg).*
*Pull requests are welcome for additional commonly used file types, except for `doc`, `xls`, `ppt`.*
*Pull requests are welcome for additional commonly used file types.*
The following file types will not be accepted:
- `.doc` - Too old and difficult to parse.
- `.xls` - Too old and difficult to parse.
- `.ppt` - Too old and difficult to parse.
- `.csv` - [Reason.](https://github.com/sindresorhus/file-type/issues/264#issuecomment-568439196)
- `.svg` - Detecting it requires a full-blown parser. Check out [`is-svg`](https://github.com/sindresorhus/is-svg) for something that mostly works.
## file-type for enterprise

@@ -384,0 +394,0 @@

@@ -125,3 +125,6 @@ 'use strict';

'aac',
'mp1'
'mp1',
'it',
's3m',
'xm'
],

@@ -241,4 +244,7 @@ mimeTypes: [

'application/x-esri-shape',
'audio/aac'
'audio/aac',
'audio/x-it',
'audio/x-s3m',
'audio/x-xm'
]
};
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc