UNPKG

file-type

Version:

Detect the file type of a file, stream, or data

277 lines (276 loc) • 3.46 kB
{ "name": "file-type", "version": "22.3.0", "description": "Detect the file type of a file, stream, or data", "license": "MIT", "repository": "sindresorhus/file-type", "funding": "https://github.com/sindresorhus/file-type?sponsor=1", "author": "Sindre Sorhus <sindresorhus@gmail.com> (https://sindresorhus.com)", "type": "module", "exports": { "types": "./source/index.d.ts", "default": "./source/index.js" }, "sideEffects": false, "engines": { "node": ">=22" }, "scripts": { "test": "xo && node --test && nz" }, "files": [ "source" ], "keywords": [ "mime", "file", "type", "magic", "archive", "image", "img", "pic", "picture", "flash", "photo", "video", "detect", "check", "is", "exif", "elf", "macho", "exe", "binary", "buffer", "uint8array", "jpg", "png", "apng", "gif", "webp", "flif", "xcf", "cr2", "cr3", "orf", "arw", "dng", "nef", "rw2", "raf", "tif", "bmp", "icns", "jxr", "psd", "indd", "zip", "tar", "rar", "gz", "bz2", "7z", "dmg", "mp4", "mid", "mkv", "webm", "mov", "avi", "mpg", "mp2", "mp3", "m4a", "ogg", "opus", "flac", "wav", "amr", "pdf", "epub", "mobi", "swf", "rtf", "woff", "woff2", "eot", "ttf", "otf", "ttc", "ico", "flv", "ps", "xz", "sqlite", "xpi", "cab", "deb", "ar", "rpm", "Z", "lz", "cfb", "mxf", "mts", "wasm", "webassembly", "blend", "bpg", "docx", "pptx", "xlsx", "3gp", "j2c", "jp2", "jpm", "jpx", "mj2", "aif", "caf", "odt", "ods", "odp", "xml", "heic", "ics", "glb", "pcap", "dsf", "dff", "lnk", "alias", "voc", "ac3", "3g2", "m4b", "m4p", "m4v", "f4a", "f4b", "f4p", "f4v", "mie", "qcp", "asf", "ogv", "ogm", "oga", "spx", "ogx", "ape", "wv", "cur", "nes", "crx", "ktx", "dcm", "mpc", "arrow", "shp", "aac", "mp1", "it", "s3m", "xm", "skp", "avif", "eps", "lzh", "pgp", "asar", "stl", "chm", "3mf", "zst", "jxl", "vcf", "jls", "pst", "dwg", "parquet", "class", "arj", "cpio", "ace", "avro", "icc", "fbx", "vsdx", "vtt", "apk", "drc", "lz4", "potx", "xltx", "dotx", "xltm", "ots", "odg", "otg", "otp", "ott", "xlsm", "docm", "dotm", "potm", "pptm", "jar", "jmp", "rm", "sav", "ppsm", "ppsx", "tar.gz", "reg", "dat", "key", "numbers", "pages", "iso" ], "dependencies": { "@tokenizer/inflate": "^0.6.0", "strtok3": "^10.6.3", "token-types": "^6.1.2", "uint8array-extras": "^1.6.0" }, "devDependencies": { "@tokenizer/token": "^0.3.0", "@types/node": "^26.6.4", "@typescript/native": "npm:typescript@^7.0.2", "commonmark": "^0.31.2", "esbuild": "^0.28.2", "get-stream": "^9.0.1", "nz": "^0.1.0", "xo": "^5.0.1" }, "xo": [ { "ignores": [ "fixture/**" ] }, { "rules": { "no-await-in-loop": "warn", "no-bitwise": "off", "unicorn/switch-case-braces": "off", "unicorn/max-nested-calls": "off", "unicorn/prefer-combined-guards": "off", "unicorn/prefer-ternary": "off", "unicorn/prefer-early-return": "off", "node-test/require-assertion": "off", "node-test/no-conditional-assertion": "off" } }, { "files": [ "package.json" ], "rules": { "package-json/valid-fields": "off" } } ] }