Socket
Socket
Sign inDemoInstall

strip-bom

Package Overview
Dependencies
2
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.0 to 0.3.1

12

index.js

@@ -18,14 +18,8 @@ 'use strict';

stripBom.stream = function () {
var through = require('through2');
var first = true;
var firstChunk = require('first-chunk-stream');
return through(function (chunk, enc, cb) {
if (first) {
first = false;
chunk = stripBom(chunk);
}
this.push(chunk);
return firstChunk({minSize: 3}, function (chunk, enc, cb) {
this.push(stripBom(chunk));
cb();
});
};
{
"name": "strip-bom",
"version": "0.3.0",
"version": "0.3.1",
"description": "Strip UTF-8 byte order mark (BOM) from a string/buffer/stream",

@@ -45,4 +45,4 @@ "license": "MIT",

"dependencies": {
"is-utf8": "^0.2.0",
"through2": "^0.4.1"
"first-chunk-stream": "^0.1.0",
"is-utf8": "^0.2.0"
},

@@ -49,0 +49,0 @@ "devDependencies": {

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc