JSPM

istextorbinary

1.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1961597
  • Score
    100M100P100Q199044F
  • License

Determines if a buffer is comprised of text or binary

Package Exports

  • istextorbinary

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (istextorbinary) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Is Text or Binary?

Build Status NPM version Gittip donate button Flattr donate button PayPayl donate button

Determines if a buffer is comprised of text or binary

Install

Node, Browserify

  • Use: require('istextorbinary')
  • Install: npm install --save istextorbinary

Ender

  • Use: require('istextorbinary')
  • Install: ender add istextorbinary

Usage

// Sync
var result = require('istextorbinary').isTextSync(filename, buffer);

// Async
require('istextorbinary').isText(filename, buffer, function(err, result){
    // ...
});

// You can supply text or buffer, or both text and buffer, the more provided, the more accurate the result
// isBinary, and isBinarySync methods also provided

History

Discover the change history by heading on over to the History.md file.

Contribute

Discover how you can contribute by heading on over to the Contributing.md file.

Backers

Maintainers

These amazing people are maintaining this project:

Sponsors

No sponsors yet! Will you be the first?

Gittip donate button Flattr donate button PayPayl donate button

Contributors

No contributors yet! Will you be the first? Discover how you can contribute by heading on over to the Contributing.md file.

License

Licensed under the incredibly permissive MIT license

Copyright © 2012+ Bevry Pty Ltd us@bevry.me (http://bevry.me)
Copyright © 2011 Benjamin Lupton b@lupton.cc (http://balupton.com)