npm file-type 17.0.0

latest releases: 19.6.0, 19.5.0, 19.4.1...
2 years ago

Breaking

  • Require Node.js 12.20 (#472) 826b4ad
  • This package is now pure ESM. Please read this.
  • Remove the /browser sub-export 287e361
    • Browser support is now included by default.
  • Moved from a default export to named exports:
    require('file-type').fromBufferimport {fileTypeFromBuffer} from 'file-type'
    require('file-type').fromFileimport {fileTypeFromFile} from 'file-type'
    require('file-type').fromStreamimport {fileTypeFromStream} from 'file-type'
    require('file-type').fromTokenizerimport {fileTypeFromTokenizer} from 'file-type'
    require('file-type').streamimport {fileTypeStream} from 'file-type'
    require('file-type').extensionsimport {supportedExtensions} from 'file-type'
    require('file-type').mimeTypesimport {supportedMimeTypes} from 'file-type'

Improvements

  • Improve WebM detection (#486) b23be62
  • Improve parsing TIFF files (#482) 82c9ccb
  • Detect both raw and BDAV versions of MPEG-2 Transport Streams (#497) 4ce6838
  • Detect XML UTF-16-BE & UTF-16-LE via pattern matching (#490) a2cf2b3
  • Support XML encoding with UTF-8 including BOM field (#491) 8bca6b4

Fixes

  • Prevent End-Of-Stream error in stream() (#468) 67c8fcb

v16.5.1...v17.0.0

Don't miss a new file-type release

NewReleases is sending notifications on new releases.