iconv-lite
Advanced tools
Comparing version 0.4.4 to 0.4.5
# 0.4.5 / 2014-11-20 | ||
* fix windows-31j and x-sjis encoding support (@nleush) | ||
* minor fix: undefined variable reference when internal error happens | ||
# 0.4.4 / 2014-07-16 | ||
@@ -3,0 +8,0 @@ |
@@ -474,2 +474,4 @@ | ||
// TODO: Check curByte is number 0 <= < 256 | ||
// Lookup in current trie node. | ||
@@ -507,3 +509,3 @@ var uCode = this.decodeTables[nodeIdx][curByte]; | ||
else | ||
throw new Error("Unknown table value when decoding: " + val); | ||
throw new Error("iconv-lite internal error: invalid decoding table value " + uCode + " at " + nodeIdx + "/" + curByte); | ||
@@ -510,0 +512,0 @@ // Write the character to buffer, handling higher planes using surrogate pair. |
@@ -50,4 +50,4 @@ | ||
'sjis': 'shiftjis', | ||
'windows-31j': 'shiftjis', | ||
'x-sjis': 'shiftjis', | ||
'windows31j': 'shiftjis', | ||
'xsjis': 'shiftjis', | ||
'windows932': 'shiftjis', | ||
@@ -169,2 +169,2 @@ '932': 'shiftjis', | ||
}; | ||
}; |
@@ -31,2 +31,4 @@ | ||
// Direct: \n, \r, \t, 0x20, 0x27-0x29, (0x2B), 0x2C-0x3A, 0x3F, 0x41-0x5A, 0x61-0x7A | ||
function utf7EncoderWrite(str) { | ||
@@ -33,0 +35,0 @@ // Naive implementation. |
{ | ||
"name": "iconv-lite", | ||
"description": "Convert character encodings in pure javascript.", | ||
"version": "0.4.4", | ||
"version": "0.4.5", | ||
"license": "MIT", | ||
@@ -20,3 +20,4 @@ | ||
"Brian White (https://github.com/mscdex)", | ||
"Mithgol (https://github.com/Mithgol)" | ||
"Mithgol (https://github.com/Mithgol)", | ||
"Nazar Leush (https://github.com/nleush)" | ||
], | ||
@@ -35,2 +36,4 @@ | ||
"scripts": { | ||
"coverage": "istanbul cover _mocha -- --grep .", | ||
"coverage-open": "open coverage/lcov-report/index.html", | ||
"test": "mocha --reporter spec --grep ." | ||
@@ -44,8 +47,9 @@ }, | ||
"mocha": "*", | ||
"request": "*", | ||
"request": "2.47", | ||
"unorm": "*", | ||
"errto": "*", | ||
"async": "*", | ||
"istanbul": "*", | ||
"iconv": "~2.1.4" | ||
} | ||
} |
@@ -6,3 +6,4 @@ ## Pure JS character encoding conversion | ||
* Doesn't need native code compilation. Works on Windows and in sandboxed environments like [Cloud9](http://c9.io). | ||
* Used in popular projects like [Grunt](http://gruntjs.com/), [Nodemailer](http://www.nodemailer.com/), [Yeoman](http://yeoman.io/) and others. | ||
* Used in popular projects like [Express.js (body_parser)](https://github.com/expressjs/body-parser), | ||
[Grunt](http://gruntjs.com/), [Nodemailer](http://www.nodemailer.com/), [Yeoman](http://yeoman.io/) and others. | ||
* Faster than [node-iconv](https://github.com/bnoordhuis/node-iconv) (see below for performance comparison). | ||
@@ -122,3 +123,5 @@ * Intuitive encode/decode API | ||
When decoding, be sure to supply a Buffer to decode() method, otherwise [bad things usually happen](https://github.com/ashtuchkin/iconv-lite/wiki/Use-Buffers-when-decoding). | ||
Untranslatable characters are set to � or ?. No transliteration is currently supported. | ||
Untranslatable characters are set to � or ?. No transliteration is currently supported. | ||
Uses BOM to determine endianness, but doesn't remove it. Use ['strip-bom' module](https://github.com/sindresorhus/strip-bom). | ||
Node versions 0.10.31 and 0.11.13 are buggy, don't use them (see #65, #77). | ||
@@ -135,2 +138,6 @@ ## Testing | ||
$ node test/performance.js | ||
$ # To view test coverage: | ||
$ npm run coverage | ||
$ open coverage/lcov-report/index.html | ||
``` | ||
@@ -140,2 +147,2 @@ | ||
[![NPM](https://nodei.co/npm-dl/iconv-lite.png)](https://nodei.co/npm/iconv-lite/) | ||
[![Codeship Status for ashtuchkin/iconv-lite](https://www.codeship.io/projects/81670840-fa72-0131-4520-4a01a6c01acc/status)](https://www.codeship.io/projects/29053) |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3804
145
323586
7
26