How to use is-utf8 - 2 common examples

To help you get started, we’ve selected a few is-utf8 examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github fanpei91 / torsniff / src / utils.js View on Github external
      return buffer.toString();
    return iconvLite.decode(buffer, 'GB18030');
github bids-standard / bids-validator / bids-validator / utils / files / readFile.js View on Github external
const checkEncoding = (file, data, cb) => {
  if (isJSONFile(file)) cb({ isUtf8: checkIfUtf8(data) })


Detect if a buffer is utf8 encoded.

Latest version published 7 years ago

Package Health Score

70 / 100
Full package analysis

Popular is-utf8 functions

Popular JavaScript code snippets

Find secure code to use in your application or website