Skip to content

Commit

Permalink
feat: v2.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
polygonplanet committed Jun 8, 2024
1 parent 5d76ce1 commit 52175eb
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 9 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ When the script is loaded, the object `Encoding` is defined in the global scope
You can use encoding.js (package name: `encoding-japanese`) directly from a CDN via a script tag:

```html
<script src="https://unpkg.com/encoding-japanese@2.1.0/encoding.min.js"></script>
<script src="https://unpkg.com/encoding-japanese@2.2.0/encoding.min.js"></script>
```

In this example we use [unpkg](https://unpkg.com/encoding-japanese/), but you can use any CDN that provides npm packages,
Expand Down
2 changes: 1 addition & 1 deletion README_ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ minify された `encoding.min.js` も使用できます。
`<script>` タグで CDN から直接 encoding.js (パッケージ名: `encoding-japanese`) を利用できます。

```html
<script src="https://unpkg.com/encoding-japanese@2.1.0/encoding.min.js"></script>
<script src="https://unpkg.com/encoding-japanese@2.2.0/encoding.min.js"></script>
```

この例では [unpkg](https://unpkg.com/encoding-japanese/) を使用していますが、
Expand Down
6 changes: 4 additions & 2 deletions encoding.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
/*!
* encoding-japanese v2.1.0 - Convert and detect character encoding in JavaScript
* encoding-japanese v2.2.0 - Convert and detect character encoding in JavaScript
* Copyright (c) 2012 polygonplanet <[email protected]>
* https://github.com/polygonplanet/encoding.js
* @license MIT
*/
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Encoding = f()}})(function(){var define,module,exports;return (function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i<t.length;i++)o(t[i]);return o}return r})()({1:[function(require,module,exports){
module.exports={
"version": "2.1.0"
"version": "2.2.0"
}
},{}],2:[function(require,module,exports){
var util = require('./util');
Expand Down Expand Up @@ -1825,6 +1825,8 @@ function handleFallback(results, bytes, fallbackOption) {
results[results.length] = 0x3B; // ;
}
break;
case 'error':
throw new Error('Character cannot be represented: [' + bytes.join(', ') + ']');
case 'ignore':
break;
}
Expand Down
4 changes: 2 additions & 2 deletions encoding.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "encoding-japanese",
"version": "2.1.0",
"version": "2.2.0",
"description": "Convert and detect character encoding in JavaScript",
"main": "src/index.js",
"files": [
Expand Down

0 comments on commit 52175eb

Please sign in to comment.