Socket
Socket
Sign inDemoInstall

fast-csv

Package Overview
Dependencies
Maintainers
2
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fast-csv - npm Package Compare versions

Comparing version 2.3.0 to 2.3.1

large.csv

4

History.md

@@ -0,1 +1,5 @@

# v2.3.1
* Now removes the byte order mark from a UTF-8 file if this is present. [#170](https://github.com/C2FO/fast-csv/pull/170)
# v2.3.0

@@ -2,0 +6,0 @@

@@ -197,2 +197,11 @@ var extended = require("../extended"),

__removeBOM: function (data) {
// Catches EFBBBF (UTF-8 BOM) because the buffer-to-string
// conversion translates it to FEFF (UTF-16 BOM)
if (data && typeof data == 'string' && data.charCodeAt(0) == '0xFEFF') {
return data.slice(1);
}
return data;
},
_transform: function (data, encoding, done) {

@@ -203,2 +212,3 @@ var lines = this.lines,

if (lineData.length > 1) {
lineData = this.__removeBOM(lineData);
this._parse(lineData, true, function (err, lineData) {

@@ -205,0 +215,0 @@ if (err) {

2

package.json
{
"name": "fast-csv",
"version": "2.3.0",
"version": "2.3.1",
"description": "CSV parser and writer",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -1,2 +0,2 @@

[![build status](https://secure.travis-ci.org/C2FO/fast-csv.png)](http://travis-ci.org/C2FO/fast-csv)
[![build status](https://secure.travis-ci.org/C2FO/fast-csv.svg)](http://travis-ci.org/C2FO/fast-csv)
# Fast-csv

@@ -166,3 +166,3 @@

If you expect the first line your csv to headers you may pass a headers option in. Setting the headers option will
If you expect the first line your CSV to be headers you may pass in a `headers` option. Setting the `headers` option will
cause change each row to an object rather than an array.

@@ -184,3 +184,3 @@

You may alternatively pass an array of header names which must match the order of each column in the csv, otherwise
You may alternatively pass an array of header names which must match the order of each column in the CSV, otherwise
the data columns will not match.

@@ -239,3 +239,3 @@

You can validate each row in the csv by providing a validate handler. If a row is invalid then a `data-invalid` event
You can validate each row in the CSV by providing a validate handler. If a row is invalid then a `data-invalid` event
will be emitted with the row and the index.

@@ -352,3 +352,3 @@

You can pass in object to any formatter function if your csv requires headers the keys of the first object will be used as the header names.
You can pass in object to any formatter function if your CSV requires headers the keys of the first object will be used as the header names.

@@ -371,3 +371,3 @@ ```javascript

You can also pass in your rows as arrays. If your csv requires headers the first row passed in will be the headers used.
You can also pass in your rows as arrays. If your CSV requires headers the first row passed in will be the headers used.

@@ -409,3 +409,3 @@ ```javascript

This is the lowest level of the write methods, it creates a stream that can be used to create a csv of unknown size and pipe to an output csv.
This is the lowest level of the write methods, it creates a stream that can be used to create a CSV of unknown size and pipe to an output CSV.

@@ -412,0 +412,0 @@ ```javascript

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc