{"_id":"encoding-japanese","_rev":"60-9c56efef399542600ed7b75acabfb781","name":"encoding-japanese","dist-tags":{"latest":"2.4.0"},"versions":{"1.0.19":{"name":"encoding-japanese","version":"1.0.19","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet"},"license":"MIT","_id":"encoding-japanese@1.0.19","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"c96e0a00ccffad404f1b1c55510ad8f131b13bc6","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.19.tgz","integrity":"sha512-szVee3/leeul9+X+BZupeSGcdW+qAh5QMgPDwmXK3gcggs7Ocgb8TVbyoQgN/te45kq5gHL3YbUzTkFYMnnUDA==","signatures":[{"sig":"MEUCIQCE3N14AKGtd2Vbh08MuzFYpjiUn044nYW5S+5OBwOeFwIgAeAp/Q0jsDv/skCUdy60fEw4FpeSSeqLEjeuEtTBnfA=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"c96e0a00ccffad404f1b1c55510ad8f131b13bc6","gitHead":"40b9aa64a343b9904e5015866ee1459bc9c6562b","scripts":{"test":"mocha tests/test"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"1.4.28","description":"Converts character encoding.","directories":{"test":"tests"},"dependencies":{},"devDependencies":{"mocha":"*"}},"1.0.20":{"name":"encoding-japanese","version":"1.0.20","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet"},"license":"MIT","_id":"encoding-japanese@1.0.20","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"b26a066640eb897d13fceb1222da4c82e40adf23","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.20.tgz","integrity":"sha512-Rh6P72uTrxpMWfkRpSSNjbSTWXPL4k5zphA+KCUmAj+Zsbuf8uU2ph5bfyMUMTtQ+8oc3FUF+CGqx0SiGKBPjw==","signatures":[{"sig":"MEUCIAjADsHuKEsMSuV+nwGkd8/BbCDhmxraFzp0CsuJAyAHAiEA1jKq7JMe8LTNAiRgt4G8ZCvuhAb9NQy3rk3zjqJ35Ek=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"b26a066640eb897d13fceb1222da4c82e40adf23","scripts":{"test":"mocha tests/test"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"1.4.28","description":"Converts character encoding.","directories":{"test":"tests"},"dependencies":{},"devDependencies":{"mocha":"*"}},"1.0.21":{"name":"encoding-japanese","version":"1.0.21","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet"},"license":"MIT","_id":"encoding-japanese@1.0.21","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"de6d9e4b8a8533bf5e67dc332ce12e93b94b83bd","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.21.tgz","integrity":"sha512-AAcJR3H1FADcoc/6JARi8NPo1Srpde31uperDIu4WHwHCOl6GmfYB4dZQ+fuceedGbUW00Xd5/MHgIiCm2EtaA==","signatures":[{"sig":"MEQCIEQsxqwwXRhq0T8qKaY0d6Ot0245NPK/vIycvJEX1GZHAiBKMt9w7id8drg3LXHvIpfMBVdzmU71OilEFedbyqwV6A==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"de6d9e4b8a8533bf5e67dc332ce12e93b94b83bd","scripts":{"test":"mocha tests/test"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"1.4.28","description":"Converts character encoding.","directories":{"test":"tests"},"dependencies":{},"devDependencies":{"mocha":""}},"1.0.23":{"name":"encoding-japanese","version":"1.0.23","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet"},"license":"MIT","_id":"encoding-japanese@1.0.23","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"2b2f7e7071460ccab3845f9fd52794d5c2602fa6","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.23.tgz","integrity":"sha512-tFVXWA33vFuyr5/6qSuOxH3sBhzBRzIi4KetlkzvHO+y1PvYsvW9KNvsMZjX+x1D3JpViGvtAhx8kb1BJZebRw==","signatures":[{"sig":"MEQCIBkAzgMSp/ChpY7X+ksAXaHPj7hv0Hn+MpR7Uf5RCrBcAiBPHkFX4FBerRX8/RSNuBgcaG6XEvrzW+DMZLeX/WxE8g==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"2b2f7e7071460ccab3845f9fd52794d5c2602fa6","scripts":{"test":"mocha tests/test"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"1.4.28","description":"Converts character encoding.","directories":{"test":"tests"},"dependencies":{},"devDependencies":{"mocha":""}},"1.0.24":{"name":"encoding-japanese","version":"1.0.24","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","base64","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet"},"license":"MIT","_id":"encoding-japanese@1.0.24","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"18b634bcf8bfc601891cc75d97a6b907e3435df9","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.24.tgz","integrity":"sha512-LajgSdj3FO40yA5U4YpJGBJAzReyoHPnvtul4LoxXMJOL58j4s2YSiSFcKjD55FVNX2hoIf46UdIf9pYiTYr1A==","signatures":[{"sig":"MEQCIFNEcC1qhHh38aaGpO1Dfr1MGqK0N77NqYISaqDFQ2nwAiBpbmtj4svLJoWdNkoDlwyWgSOMLzSDuO3PrYdQkhCXgw==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"18b634bcf8bfc601891cc75d97a6b907e3435df9","scripts":{"test":"mocha tests/test"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"1.4.28","description":"Converts character encoding.","directories":{"test":"tests"},"dependencies":{},"devDependencies":{"mocha":""}},"1.0.25":{"name":"encoding-japanese","version":"1.0.25","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","base64","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet"},"license":"MIT","_id":"encoding-japanese@1.0.25","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"f6eac6e85a4d8b7e4ed0718aa817d251466dca38","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.25.tgz","integrity":"sha512-RYEO2QHi86B5ZVwxlowndBmmvN/4MNDbQYyRkq8ZJNy7DhxXD4o2yBO7k/DcsKMiydw43ZR2S1gSb1KW9K3JIA==","signatures":[{"sig":"MEUCIE1hlQkmc8/3xVUXt1EpgjKouwKXh2lK+cc6oI0OVWLPAiEA6cMkukvtlpYc8CfimAE17xofIeKr8SQu4Wn1ReK5EOY=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"f6eac6e85a4d8b7e4ed0718aa817d251466dca38","scripts":{"test":"mocha tests/test","minify":"grunt"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"3.9.5","description":"Converts character encoding.","directories":{"test":"tests"},"_nodeVersion":"6.2.1","dependencies":{},"devDependencies":{"grunt":"^1.0.1","mocha":"^3.1.2","uglify-js":"^2.7.4","grunt-contrib-uglify":"^2.0.0"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese-1.0.25.tgz_1478127942300_0.3704801315907389","host":"packages-18-east.internal.npmjs.com"}},"1.0.26":{"name":"encoding-japanese","version":"1.0.26","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","base64","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet"},"license":"MIT","_id":"encoding-japanese@1.0.26","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"240a7a852d966dc07c4dc7d079a67b5777a62ba0","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.26.tgz","integrity":"sha512-wpxUTdIoNsj7XtM9mYd1d6CNnJCV4Fyo4fAfHM0wUCHCxVEVcSrigJ06BlbeIo8+ncYKfovUF/bFSAqiuCj6YA==","signatures":[{"sig":"MEUCIFGQ5AaUgh9BBLwxAjXG5UnXqjwMbMvZmLKd8unZ7hYfAiEA6simNFbxb63uyF7GLXdm/Ts5I171f5jk38NM/fuGECw=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"240a7a852d966dc07c4dc7d079a67b5777a62ba0","scripts":{"test":"mocha tests/test","minify":"grunt"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"4.0.5","description":"Converts character encoding.","directories":{"test":"tests"},"_nodeVersion":"7.7.1","dependencies":{},"devDependencies":{"grunt":"^1.0.1","mocha":"^3.1.2","uglify-js":"^2.7.4","grunt-contrib-uglify":"^2.0.0"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese-1.0.26.tgz_1503306483064_0.4281555931083858","host":"s3://npm-registry-packages"}},"1.0.28":{"name":"encoding-japanese","version":"1.0.28","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","base64","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","_id":"encoding-japanese@1.0.28","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"9fa47417191bcd02f70c3dada287b5ce89053495","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.28.tgz","integrity":"sha512-Lb7+wrNfTK1whcY2VTYMzx9LovAArZkYTWAcPk5v72LzHjgi6bvSwH+/SXca9Exb5o/1HYBQIFwX0ymad8Q/OQ==","signatures":[{"sig":"MEUCIQDxt2LDEuBwEWrk4IF/VJ55lec0e4bp0nGlABgAJjKhaAIgEgyPMiYx0Jp7AwYIxPfJQsf3BzCPYgMJ5qrnHeC9q+c=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"encoding.js","_from":".","_shasum":"9fa47417191bcd02f70c3dada287b5ce89053495","scripts":{"test":"npm run build && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=200 -v","minify":"uglifyjs encoding.js -o encoding.min.js --source-map \"url='encoding.min.js.map'\" --comments -c warnings=false -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"4.0.5","description":"Converts character encoding","directories":{"test":"tests"},"_nodeVersion":"9.3.0","dependencies":{},"devDependencies":{"mocha":"^5.0.0","watchify":"^3.9.0","bannerify":"^1.0.1","uglify-js":"^3.3.8","uglifyify":"^4.0.5","browserify":"^15.2.0","power-assert":"^1.4.4"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese-1.0.28.tgz_1517466748924_0.2719013290479779","host":"s3://npm-registry-packages"}},"1.0.29":{"name":"encoding-japanese","version":"1.0.29","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","base64","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","_id":"encoding-japanese@1.0.29","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"f66db17f2afaadf9a38b6b0227c0c877d2f2c5b1","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.29.tgz","fileCount":29,"integrity":"sha512-nJNBvb1EO/aYgZzmfL9E79ZM328bJrlL5igo7Z/8RvwiDWy03OksgFfISWAm/tYCeD+x9VyNkJXGv7EHlLUUdA==","signatures":[{"sig":"MEQCIB6M+wfbylG2cbIonB8Xnl1BW509aQzyxASOXAASbQ4LAiATYz+KrL7j3QfWXc521otCg/qrlWPyymzkUZp+7F1gEQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1273586,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJa9XkyCRA9TVsSAnZWagAAZDsP/2lgD/NT5pIEnWLyYd8Z\nmkwxOwrIcIwBhysNjKMlloZMJRQ5fOKjVpxqfma1Enmb5Wd4kCWgMRvQ/4j/\n/x0HMH5gstuotTiPgP5EWaWnWIpXnl0FMvYAl4EAkRSCYhWCGRu5NLG8hB0W\nLqta6dicbhP2lxYUrCN0A+3OPSzk5WHe/iUA3IwDJKCRjcsELyXoN4HYYxqP\noOelwHaItXKHzSpYsR6KubrUFYxwQ4EDHy5/tCEkZzW7w0qvds/ws4cjDkZ7\nVfnpo7THobeQyatF9VKxppNWyFe6QVpyEzcbUZWbcTxUJ0txhnAz0Fx433Pi\nk6SIc+M5J4L+iREZdF7yP2OiKj8Vfu9tMFUagBpR58r9uae/p5Q3qh9jYHVe\nGCr5hP/goazWfw6LalnTLWTXLUeqW3geWVHB3LOG83k+sVGBLI2WM6XBJItD\ntBN7DfMALCBVB8Q0SAtHbDwnU4uw/1RX/EV+9aMDl1WeOueAGeB2jbuGWfi7\n/7GrYjw0Hex7E5KOMbOfYpHexRDT9Hq7V+RYjhjTmjbxsVgefeHJWIo+TQAi\nuWLdcd6cLb7+dvba8wb15Q8FDdlJj/86DMUzzlX7kRkONmibLXM1ap9yCz3u\nzxR4V3plT+uxt22BWeBdK2ff3qRpxsXBYLM/Kr6GO11PjellzdECv1arWNE+\n8Xpd\r\n=B+Ix\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/index.js","_from":".","_shasum":"f66db17f2afaadf9a38b6b0227c0c877d2f2c5b1","scripts":{"test":"npm run build && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=200 -v","minify":"uglifyjs encoding.js -o encoding.min.js --source-map \"url='encoding.min.js.map'\" --comments -c warnings=false -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"4.0.5","description":"Converts character encoding","directories":{"test":"tests"},"_nodeVersion":"9.3.0","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"mocha":"^5.0.0","watchify":"^3.9.0","bannerify":"^1.0.1","uglify-js":"^3.3.8","uglifyify":"^5.0.0","browserify":"^16.2.2","power-assert":"^1.4.4"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese_1.0.29_1526036784590_0.913774334054448","host":"s3://npm-registry-packages"}},"1.0.30":{"name":"encoding-japanese","version":"1.0.30","keywords":["encoding","charset","iconv","japanese","unicode","utf","utf-8","utf-16","utf-32","sjis","shift_jis","eucjp","euc-jp","jis","iso-2022-jp","base64","convert","detect","urlencode","urldecode"],"author":{"name":"polygon planet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","_id":"encoding-japanese@1.0.30","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"537c4d62881767925d601acb4c79fb14db81703a","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-1.0.30.tgz","fileCount":30,"integrity":"sha512-bd/DFLAoJetvv7ar/KIpE3CNO8wEuyrt9Xuw6nSMiZ+Vrz/Q21BPsMHvARL2Wz6IKHKXgb+DWZqtRg1vql9cBg==","signatures":[{"sig":"MEQCIAG3OklzkMAC0GqJc4L+XxPPobRok/ks6xJSOp+o2nKdAiADzljsYcCMSXmiPNMr6l19G6wBgRj/PqmPXI7UEGbycA==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1274813,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdelV4CRA9TVsSAnZWagAAlz0P/3EISSeULYhrh0veMby+\npf5LlYHlmF/TdIkugim9d+lm+nMciEJQuiWGe/n85JHoREZY6SQlR0mAF+uL\njSfg0gmgALQP/T9w4I1z9n8z03GJJUM1mXwPjBAYFDqsUlAprHvvhMOunzgw\nEjB0hGrKyrhsfsaqYpcuVAyoZsJOwXNjwrKFvbLt7PQZZhO4PY6HZIeH8Mzz\ngUkHMOV+knBsch8O1e+ug0DqXr1yGz80psPBVLKSEFoELlMTat/rZiBtKjoI\nSeVJ8BEcny6n52VXEQqStWOn/pYVlwW8wVkOFLwmUr5ER8XVxhG65RBkIvOU\nfyXRyiP2HcVitSsn8SsVyefQWDTlw7tH3owjIleZ501rA4VOem6cVWpplK07\n3Dyqz0vnRJ28I6/dygRJzN0jl6J4o3pOpmA9wk8TqSUjeRy3m5+74x8wj4OO\njTkSj90lgTAOryrkrSXR3yPVaQqBkLUVooY+1EytvJGwB31zv5DbCqMzcnM5\nnRL2Qblthy7mkYkbs/PwtdT2elt9R1+iXSy244otlTykCtidcjlNRbQvHGQC\nHdCD8jZXyEXuZCGYJ0LBHjQ5c9qXR/0bWIES7GGwTTF4gHBp44DclzpFCadg\nqfsds/kzXFeu7iilSxvOrvxN887hE6EsW3cypEweFtWOW5//8jlGrH4V3n+r\nYspI\r\n=xZH8\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/index.js","scripts":{"test":"npm run build && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=200 -v","minify":"uglifyjs encoding.js -o encoding.min.js --source-map \"url='encoding.min.js.map'\" --comments -c -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"6.9.0","description":"Convert or detect character encoding in JavaScript","directories":{"test":"tests"},"_nodeVersion":"8.10.0","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"mocha":"^6.2.0","watchify":"^3.11.1","bannerify":"^1.0.1","uglify-js":"^3.6.0","uglifyify":"^5.0.2","browserify":"^16.5.0","power-assert":"^1.6.1"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese_1.0.30_1568298360064_0.19588362521194336","host":"s3://npm-registry-packages"}},"2.0.0":{"name":"encoding-japanese","version":"2.0.0","keywords":["base64","charset","convert","detect","encoding","euc-jp","eucjp","iconv","iso-2022-jp","japanese","jis","shift_jis","sjis","unicode","urldecode","urlencode","utf-16","utf-32","utf-8"],"author":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","_id":"encoding-japanese@2.0.0","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"fa0226e5469e7b5b69a04fea7d5481bd1fa56936","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-2.0.0.tgz","fileCount":19,"integrity":"sha512-++P0RhebUC8MJAwJOsT93dT+5oc5oPImp1HubZpAuCZ5kTLnhuuBhKHj2jJeO/Gj93idPBWmIuQ9QWMe5rX3pQ==","signatures":[{"sig":"MEYCIQDaSRdx9Mw3QFFdwjZsalNotbj+1Cu7hP3wLAOE6OeHjQIhAKfxkiS6tGYNkSU0qvDS2JMhA6TltzGtnKayD2J1Vrlv","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1187130,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiQs1iACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmpeiw//bN/gSJkkyl4wA1Q2oCiFqDSknrGoFSk/WQn220IBI1p1myJp\r\nf8QKnsR/cHVYXpxp8QQfHxhQHGtnMVN6mg16PY3G38SsZ8Q22Qh4Zxs6F1Al\r\ndnEGJ8ay/0jaKewFSO49ccXqbyh8ic3n3Itx93ZuQPYiP0Pr+35I2G2mbB2i\r\nc5BA0QrvvSA7salNB4ZsBRO2mtPqsqYZjaWTpVqpbYD4Nq6tow/nVdZMMXvn\r\nU74e5ioGQLsrI/c3Nmdji1fkjI5kksVuZ2uewne+lNIeFbj+YUqAu47Mavsy\r\nrlW2lEVtOf6vDC/hLy3ZC1SRD4hVb5GSqDTNGZFY+sHq1BCD5AtMl0aB/Yxd\r\nApOvdHvPkdLZvfdcPNTxxoMv/H1s26upTK35eqAqFGBTIb/x/dfYUSLwOTlk\r\nBDa/X6OIvKbB1xoj8vS6B2AwBeJX7Isibft4oGqih/GHXkt5gMLaIrSI7ZYN\r\nu/ImgzJwzrunF39KkX46kvJgFaHJwm4L8kSREkCQNZsbpKQ+jdpBeVsaQEyq\r\ngjNJAGmpqBAnCP08mTqg1OmFXHWfqV2vpxcK32NrAVF9Y1shl47glVr0NbkI\r\n/sfWbQDjXqDaG4ZGjvulmbNOzyq//whiziQvqQFWIPoRlllu41hBSZnWtf8H\r\nMBp1jLj5ML2RGE5maRkJvt680iq3NpMlNnU=\r\n=N70Y\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/index.js","engines":{"node":">=8.10.0"},"scripts":{"test":"eslint . && npm run build && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=300 -v","minify":"uglifyjs encoding.js -o encoding.min.js --source-map \"url='encoding.min.js.map'\" --comments -c -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"browserify":{"transform":["package-json-versionify"]},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"6.14.11","description":"Convert or detect character encoding in JavaScript","directories":{},"_nodeVersion":"14.16.0","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"mocha":"^9.2.2","eslint":"^8.12.0","watchify":"^4.0.0","bannerify":"^1.0.1","uglify-js":"^3.15.3","uglifyify":"^5.0.2","browserify":"^17.0.0","power-assert":"^1.6.1","package-json-versionify":"^1.0.4"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese_2.0.0_1648545122109_0.8300633255143426","host":"s3://npm-registry-packages"}},"2.1.0":{"name":"encoding-japanese","version":"2.1.0","keywords":["base64","charset","convert","detect","encoding","euc-jp","eucjp","iconv","iso-2022-jp","japanese","jis","shift_jis","sjis","unicode","urldecode","urlencode","utf-16","utf-32","utf-8"],"author":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","_id":"encoding-japanese@2.1.0","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"5d3c2b652c84ca563783b86907bf5cdfe9a597e2","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-2.1.0.tgz","fileCount":17,"integrity":"sha512-58XySVxUgVlBikBTbQ8WdDxBDHIdXucB16LO5PBHR8t75D54wQrNo4cg+58+R1CtJfKnsVsvt9XlteRaR8xw1w==","signatures":[{"sig":"MEYCIQDQD7vxD5TH2CelQVLM4LZmSDZzQfnYKGwdx0cWNbgm7gIhAIlLvoRlCyEF9YWG+tevizd6xyEMlEpw9p5MTLFU/MMH","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":851860},"main":"src/index.js","engines":{"node":">=8.10.0"},"scripts":{"test":"eslint . && npm run build && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=300 -v","minify":"uglifyjs encoding.js -o encoding.min.js --comments -c -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"browserify":{"transform":["package-json-versionify"]},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"9.5.1","description":"Convert and detect character encoding in JavaScript","directories":{},"_nodeVersion":"18.16.0","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"mocha":"^10.3.0","eslint":"^8.57.0","watchify":"^4.0.0","bannerify":"^1.0.1","uglify-js":"^3.17.4","uglifyify":"^5.0.2","browserify":"^17.0.0","power-assert":"^1.6.1","package-json-versionify":"^1.0.4"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese_2.1.0_1711010401496_0.8543863776037137","host":"s3://npm-registry-packages"}},"2.2.0":{"name":"encoding-japanese","version":"2.2.0","keywords":["base64","charset","convert","detect","encoding","euc-jp","eucjp","iconv","iso-2022-jp","japanese","jis","shift_jis","sjis","unicode","urldecode","urlencode","utf-16","utf-32","utf-8"],"author":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","_id":"encoding-japanese@2.2.0","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"0ef2d2351250547f432a2dd155453555c16deb59","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-2.2.0.tgz","fileCount":17,"integrity":"sha512-EuJWwlHPZ1LbADuKTClvHtwbaFn4rOD+dRAbWysqEOXRc2Uui0hJInNJrsdH0c+OhJA4nrCBdSkW4DD5YxAo6A==","signatures":[{"sig":"MEUCIBAMfDEiVjHX1quTx3fToKuKGeVss7Iu/92SD8S+ZkCOAiEA21AyOHbtrujkac/46S5KRr2dbgaWbBY6dW4caG+moaQ=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":854283},"main":"src/index.js","engines":{"node":">=8.10.0"},"scripts":{"test":"eslint . && npm run build && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=300 -v","minify":"uglifyjs encoding.js -o encoding.min.js --comments -c -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"browserify":{"transform":["package-json-versionify"]},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"9.8.1","description":"Convert and detect character encoding in JavaScript","directories":{},"_nodeVersion":"18.18.0","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"mocha":"^10.4.0","eslint":"^8.57.0","watchify":"^4.0.0","bannerify":"^1.0.1","uglify-js":"^3.17.4","uglifyify":"^5.0.2","browserify":"^17.0.0","power-assert":"^1.6.1","package-json-versionify":"^1.0.4"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese_2.2.0_1717862348273_0.4781649043396716","host":"s3://npm-registry-packages"}},"2.3.0":{"name":"encoding-japanese","version":"2.3.0","keywords":["base64","charset","convert","detect","encoding","euc-jp","eucjp","iconv","iso-2022-jp","japanese","jis","shift_jis","sjis","unicode","urldecode","urlencode","utf-16","utf-32","utf-8"],"author":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","_id":"encoding-japanese@2.3.0","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"homepage":"https://github.com/polygonplanet/encoding.js","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"83e6d71a31fa3a10c9b2cfb14f4da6bb5009c0fe","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-2.3.0.tgz","fileCount":18,"integrity":"sha512-eQyh1vzHz13DUkZcJO+0IOAoKXRQwKV5IBffeuYsWZyRLGiSzfzXObCqWvqFXdX0UU8qOk+lBXbkUhMCpdJe4Q==","signatures":[{"sig":"MEUCIQCLrwrgR0iR5LlWrXK8pyKOcyHf6ago9BNCDSVBK/eg5gIgdH5wpYa6vxB3mH22WvBOGrf7oFzm/y6jroeOulO7LT0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIQDZ/Xwy2C3pFeIQrRjiSPimZl7Fe25cbp+7wIX3e/uungIgNVvkfjATFYuyiwVOMDM4AHK7+hdw9CnIJVzgZZl7t1M=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":866236},"main":"src/index.js","engines":{"node":">=18.0.0"},"scripts":{"test":"eslint . && npm run build && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=300 -v","minify":"uglifyjs encoding.js -o encoding.min.js --comments -c -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare"},"_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"browserify":{"transform":["package-json-versionify"]},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"11.6.2","description":"Convert and detect character encoding in JavaScript","directories":{},"_nodeVersion":"24.13.0","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"mocha":"^11.8.0","eslint":"^8.57.0","watchify":"^4.0.0","bannerify":"^1.0.1","uglify-js":"^3.19.3","browserify":"^17.0.1","package-json-versionify":"^1.0.4"},"_npmOperationalInternal":{"tmp":"tmp/encoding-japanese_2.3.0_1788021421961_0.7267273950856366","host":"s3://npm-registry-packages-npm-production"}},"2.4.0":{"_id":"encoding-japanese@2.4.0","bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"dist":{"shasum":"9d19fd65d76d3d5ad7aeb1772f843674c0c2cc36","tarball":"https://registry.npmjs.org/encoding-japanese/-/encoding-japanese-2.4.0.tgz","fileCount":20,"integrity":"sha512-PE0KjlsDy9JSsoU4C2Q8NXb1kC4c+bZRac9ZvHXUE4q1Ht63gScKMdEy9jst9+Fi3M4eDkqzkEhBZvix4blP2A==","signatures":[{"sig":"MEYCIQCXybomnZGsJQr941MxQIdvsuMIsP5LdcTzq7Am57VVkAIhAMkOhHb0IKJLYrdq8gG1fFmst0UC03al8Wui3UUW6M2Y","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIEy+ytZxjuoUhdAY9PE98RRLJ2HVsDPmJkFvPHjWCo8oAiAwxivixyEa5CFOIFYVXSsgWcb+/+FFtSj7tkoD3DYjYg=="}],"unpackedSize":875313},"main":"src/index.js","name":"encoding-japanese","types":"index.d.ts","author":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"engines":{"node":">=18.0.0"},"license":"MIT","scripts":{"lint":"eslint .","test":"npm run build && npm run test:types && mocha tests/test","build":"npm run compile && npm run minify","watch":"watchify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare --poll=300 -v","minify":"uglifyjs encoding.js -o encoding.min.js --comments -c -m -b ascii_only=true,beautify=false","compile":"browserify src/index.js -o encoding.js -s Encoding -p [ bannerify --file src/banner.js ] --no-bundle-external --bare","test:types":"tsc --project tsconfig.types.json"},"version":"2.4.0","_npmUser":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"homepage":"https://github.com/polygonplanet/encoding.js","keywords":["encoding","charset","convert","detect","japanese","iconv","shift-jis","cp932","euc-jp","jis","utf-8","unicode","utf-16","base64","urlencode","urldecode","utf8","shift_jis","sjis","eucjp"],"browserify":{"transform":["package-json-versionify"]},"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"_npmVersion":"11.6.2","description":"Convert and detect character encodings in JavaScript","directories":{},"maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"_nodeVersion":"24.13.0","_hasShrinkwrap":false,"devDependencies":{"mocha":"^11.8.0","eslint":"^10.9.1","globals":"^17.12.0","watchify":"^4.0.0","bannerify":"^1.0.1","uglify-js":"^3.19.3","@eslint/js":"^10.0.1","browserify":"^17.0.1","typescript":"^7.0.2","@types/node":"^26.5.0","package-json-versionify":"^1.0.4","@stylistic/eslint-plugin":"^5.10.0"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/encoding-japanese_2.4.0_1789393892107_0.9344888643885136"}}},"time":{"created":"2014-09-13T15:50:38.087Z","modified":"2026-09-14T13:51:32.376Z","1.0.7":"2014-09-13T15:50:38.087Z","1.0.8":"2014-09-14T08:43:59.893Z","1.0.9":"2014-09-24T15:27:38.946Z","1.0.10":"2014-11-21T22:30:52.758Z","1.0.11":"2014-11-28T20:21:19.371Z","1.0.12":"2014-11-29T04:58:27.285Z","1.0.13":"2014-12-07T03:34:06.699Z","1.0.14":"2014-12-13T11:12:46.379Z","1.0.15":"2014-12-13T13:10:04.401Z","1.0.16":"2014-12-14T19:17:29.870Z","1.0.17":"2014-12-15T02:58:27.781Z","1.0.18":"2014-12-16T10:41:19.455Z","1.0.19":"2014-12-16T11:28:40.227Z","1.0.20":"2014-12-17T12:47:38.369Z","1.0.21":"2015-02-12T11:17:00.282Z","1.0.23":"2015-04-06T11:11:58.355Z","1.0.24":"2015-09-22T07:55:29.174Z","1.0.25":"2016-11-02T23:05:44.512Z","1.0.26":"2017-08-21T09:08:03.161Z","1.0.28":"2018-02-01T06:32:29.697Z","1.0.29":"2018-05-11T11:06:24.747Z","1.0.30":"2019-09-12T14:26:00.230Z","2.0.0":"2022-03-29T09:12:02.342Z","2.1.0":"2024-03-21T08:40:01.649Z","2.2.0":"2024-06-08T15:59:08.524Z","2.3.0":"2026-08-29T16:37:02.059Z","2.4.0":"2026-09-14T13:51:32.211Z"},"bugs":{"url":"https://github.com/polygonplanet/encoding.js/issues"},"author":{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"},"license":"MIT","homepage":"https://github.com/polygonplanet/encoding.js","keywords":["encoding","charset","convert","detect","japanese","iconv","shift-jis","cp932","euc-jp","jis","utf-8","unicode","utf-16","base64","urlencode","urldecode","utf8","shift_jis","sjis","eucjp"],"repository":{"url":"git+https://github.com/polygonplanet/encoding.js.git","type":"git"},"description":"Convert and detect character encodings in JavaScript","maintainers":[{"name":"polygonplanet","email":"polygon.planet.aqua@gmail.com"}],"readme":"encoding.js\n===========\n\n[![NPM Version](https://img.shields.io/npm/v/encoding-japanese.svg)](https://www.npmjs.com/package/encoding-japanese)\n[![GitHub Actions Build Status](https://github.com/polygonplanet/encoding.js/actions/workflows/ci.yml/badge.svg)](https://github.com/polygonplanet/encoding.js/actions)\n[![License](https://img.shields.io/npm/l/encoding-japanese.svg)](https://github.com/polygonplanet/encoding.js/blob/master/LICENSE)\n\nConvert and detect character encodings in JavaScript.\n\n[**README (日本語)**](README_ja.md)\n\n## Table of contents\n\n- [Features](#features)\n  * [How to Handle Encoded Data as Strings?](#how-to-handle-encoded-data-as-strings)\n- [Installation](#installation)\n  * [npm](#npm)\n    + [TypeScript](#typescript)\n  * [Browser (standalone)](#browser-standalone)\n  * [CDN](#cdn)\n- [Supported encodings](#supported-encodings)\n  * [About `SJIS`](#about-sjis)\n  * [About `UNICODE`](#about-unicode)\n- [Example usage](#example-usage)\n- [Demo](#demo)\n  * [Playground](#playground)\n  * [Sample file encoding conversion demo](#sample-file-encoding-conversion-demo)\n  * [User-selected file encoding conversion and detection demo](#user-selected-file-encoding-conversion-and-detection-demo)\n- [API](#api)\n  * [`detect` : Detects character encoding](#encodingdetect-data-encodings)\n  * [`convert` : Converts character encoding](#encodingconvert-data-to-from)\n    + [Specifying conversion options with an object](#specifying-conversion-options-with-an-object)\n    + [Specify the return type by the `type` option](#specify-the-return-type-by-the-type-option)\n    + [Specify handling for unrepresentable characters](#specify-handling-for-unrepresentable-characters)\n    + [Replacing characters with HTML entities when they cannot be represented](#replacing-characters-with-html-entities-when-they-cannot-be-represented)\n    + [Ignoring characters when they cannot be represented](#ignoring-characters-when-they-cannot-be-represented)\n    + [Throwing an Error when they cannot be represented](#throwing-an-error-when-they-cannot-be-represented)\n    + [Specify BOM in UTF-16](#specify-bom-in-utf-16)\n  * [`urlEncode` : Encodes to percent-encoded string](#encodingurlencode-data)\n  * [`urlDecode` : Decodes from percent-encoded string](#encodingurldecode-string)\n  * [`base64Encode` : Encodes to Base64 formatted string](#encodingbase64encode-data)\n  * [`base64Decode` : Decodes from Base64 formatted string](#encodingbase64decode-string)\n  * [`codeToString` : Converts character code array to string](#encodingcodetostring-code)\n  * [`stringToCode` : Converts string to character code array](#encodingstringtocode-string)\n  * [Japanese Zenkaku/Hankaku conversion](#japanese-zenkakuhankaku-conversion)\n- [Other examples](#other-examples)\n  * [Example using the `Fetch API` and Typed Arrays (Uint8Array)](#example-using-the-fetch-api-and-typed-arrays-uint8array)\n  * [Convert encoding for file using the File APIs](#convert-encoding-for-file-using-the-file-apis)\n- [Contributing](#contributing)\n- [License](#license)\n\n## Features\n\nencoding.js is a JavaScript library for converting and detecting character encodings,\nsupporting both Japanese character encodings (`Shift_JIS`, `EUC-JP`, `ISO-2022-JP`) and Unicode formats (`UTF-8`, `UTF-16`).\n\nSince JavaScript string values are internally encoded as UTF-16 code units\n([ref: ECMAScript® 2019 Language Specification - 6.1.4 The String Type](https://www.ecma-international.org/ecma-262/10.0/index.html#sec-ecmascript-language-types-string-type)),\ndata in other encodings cannot be handled directly as JavaScript strings.\nencoding.js works around this limitation by representing encoded data as arrays of numeric code values instead of strings, enabling conversion between different character encodings.\nFor example, `[130, 160]` represents \"あ\" in Shift_JIS.\n\nThese character code arrays can also be passed as typed arrays (such as `Uint8Array`) or as Node.js `Buffer` objects.\n\n### How to Handle Encoded Data as Strings?\n\nNumeric arrays of character codes can be converted to strings using methods such as [`Encoding.codeToString`](#encodingcodetostring-code).\nHowever, due to the JavaScript specifications mentioned above, some character encodings may not be handled properly when converted directly to strings.\n\nIf you need a string representation, [`Encoding.urlEncode`](#encodingurlencode-data) and\n[`Encoding.urlDecode`](#encodingurldecode-string) can convert numeric arrays to and from\npercent-encoded strings such as `'%82%A0'`.\nSimilarly, [`Encoding.base64Encode`](#encodingbase64encode-data) and\n[`Encoding.base64Decode`](#encodingbase64decode-string) can convert numeric arrays to and from Base64 strings.\n\n## Installation\n\n### npm\n\nencoding.js is published under the package name `encoding-japanese` on npm.\n\n```bash\nnpm install --save encoding-japanese\n```\n\n#### Using ES6 `import`\n\n```javascript\nimport Encoding from 'encoding-japanese';\n```\n\n#### Using CommonJS `require`\n\n```javascript\nconst Encoding = require('encoding-japanese');\n```\n\n#### TypeScript\n\nTypeScript type definitions for encoding.js are available at [@types/encoding-japanese](https://www.npmjs.com/package/@types/encoding-japanese) (thanks to [@rhysd](https://github.com/rhysd)).\n\n```bash\nnpm install --save-dev @types/encoding-japanese\n```\n\n### Browser (standalone)\n\nTo use encoding.js in a browser environment, you can either install it via npm or download it directly from the [release list](https://github.com/polygonplanet/encoding.js/tags).\nThe package includes both `encoding.js` and `encoding.min.js`.\n\nNote: Cloning the repository via `git clone` might give you access to the *master* (or *main*) branch, which could still be in a development state.\n\n```html\n<!-- To include the full version -->\n<script src=\"encoding.js\"></script>\n\n<!-- Or, to include the minified version for production -->\n<script src=\"encoding.min.js\"></script>\n```\n\nWhen the script is loaded, the object `Encoding` is defined in the global scope (i.e., `window.Encoding`).\n\n### CDN\n\nYou can use encoding.js (package name: `encoding-japanese`) directly from a CDN via a script tag:\n\n```html\n<script src=\"https://unpkg.com/encoding-japanese@2.4.0/encoding.min.js\"></script>\n```\n\nIn this example we use [unpkg](https://unpkg.com/encoding-japanese/), but you can use any CDN that provides npm packages,\nfor example [cdnjs](https://cdnjs.com/libraries/encoding-japanese) or [jsDelivr](https://www.jsdelivr.com/package/npm/encoding-japanese).\n\n## Supported encodings\n\n|Value in encoding.js|[`detect()`](#encodingdetect-data-encodings)|[`convert()`](#encodingconvert-data-to-from)|MIME Name (Note)|\n|:------:|:----:|:-----:|:---|\n|ASCII   |✓    |       |US-ASCII (Code point range: `0-127`)|\n|BINARY  |✓    |       |(Binary string. Code point range: `0-255`)|\n|EUCJP   |✓    |✓     |EUC-JP|\n|JIS     |✓    |✓     |ISO-2022-JP|\n|SJIS    |✓    |✓     |Shift_JIS, Windows-31J (*See [About `SJIS`](#about-sjis) below)|\n|UTF8    |✓    |✓     |UTF-8|\n|UTF16   |✓    |✓     |UTF-16|\n|UTF16BE |✓    |✓     |UTF-16BE (big-endian)|\n|UTF16LE |✓    |✓     |UTF-16LE (little-endian)|\n|UTF32   |✓    |       |UTF-32|\n|UNICODE |✓    |✓     |(JavaScript string. *See [About `UNICODE`](#about-unicode) below) |\n\n### About `SJIS`\n\nStrictly speaking, Shift_JIS and CP932 (also known as Windows-31J, MS932, SJIS-win, and other names) are different character encodings.\nFollowing common usage, encoding.js defines encodings in the Shift_JIS family as `SJIS`.\n\n`SJIS` covers CP932, an extension of Shift_JIS.\nIn addition to JIS X 0201 and JIS X 0208, it supports the following CP932 extension areas:\n\n|Area                                |Code range         |[`detect()`](#encodingdetect-data-encodings)|[`convert()`](#encodingconvert-data-to-from)|\n|:-----------------------------------|:------------------|:----:|:----:|\n|NEC special characters              |`0x8740` - `0x879C`|✓    |✓    |\n|NEC-selected IBM extended characters|`0xED40` - `0xEEFC`|✓    |✓    |\n|User-defined area (外字 / Gaiji)    |`0xF040` - `0xF9FC`|✓    |      |\n|IBM extended characters             |`0xFA40` - `0xFC4B`|✓    |✓    |\n\nThe user-defined area is detected as `SJIS`, but it cannot be converted because its character assignments are not defined by any standard.\nDuring conversion, characters in this area are replaced with `?` (U+003F).\n\n### About `UNICODE`\n\nIn encoding.js, `UNICODE` represents JavaScript strings (e.g., `\"hello\"` or `\"こんにちは\"`)\nand is defined as the internal character representation used by JavaScript.\n\nAs mentioned in the [Features](#features) section, JavaScript strings are internally encoded using UTF-16 code units.\nThis means other character encodings cannot be directly handled without conversion.\nTherefore, specify `UNICODE` when converting data to a form that can be properly represented as a JavaScript string.\n\n(Note: Even if your HTML file is UTF-8 encoded, you should specify `UNICODE` instead of `UTF8` when handling data as JavaScript strings.)\n\nWhen using [`Encoding.convert`](#encodingconvert-data-to-from),\nif you specify a character encoding other than `UNICODE` (such as `UTF8` or `SJIS`),\nthe values in the returned character code array will range from `0` to `255` (byte array).\nHowever, if you specify `UNICODE`, the values will range from `0` to `65535`,\nwhich corresponds to the range of values returned by `String.prototype.charCodeAt()` (UTF-16 code units).\n\n## Example usage\n\nConvert character encoding from JavaScript string (`UNICODE`) to `SJIS`.\n\n```javascript\nconst unicodeArray = Encoding.stringToCode('こんにちは'); // Convert string to code array\nconst sjisArray = Encoding.convert(unicodeArray, {\n  to: 'SJIS',\n  from: 'UNICODE'\n});\nconsole.log(sjisArray);\n// [130, 177, 130, 241, 130, 201, 130, 191, 130, 205] ('こんにちは' array in SJIS)\n```\n\nConvert character encoding from `SJIS` to `UNICODE`.\n\n```javascript\nconst sjisArray = [\n  130, 177, 130, 241, 130, 201, 130, 191, 130, 205\n]; // 'こんにちは' array in SJIS\n\nconst unicodeArray = Encoding.convert(sjisArray, {\n  to: 'UNICODE',\n  from: 'SJIS'\n});\nconst str = Encoding.codeToString(unicodeArray); // Convert code array to string\nconsole.log(str); // 'こんにちは'\n```\n\nDetect character encoding.\n\n```javascript\nconst data = [\n  227, 129, 147, 227, 130, 147, 227, 129, 171, 227, 129, 161, 227, 129, 175\n]; // 'こんにちは' array in UTF-8\n\nconst detectedEncoding = Encoding.detect(data);\nconsole.log(`Character encoding is ${detectedEncoding}`); // 'Character encoding is UTF8'\n```\n\n(Node.js) Example of reading a text file written in `SJIS`.\n\n```javascript\nconst fs = require('fs');\nconst Encoding = require('encoding-japanese');\n\nconst sjisBuffer = fs.readFileSync('./sjis.txt');\nconst unicodeArray = Encoding.convert(sjisBuffer, {\n  to: 'UNICODE',\n  from: 'SJIS'\n});\nconsole.log(Encoding.codeToString(unicodeArray));\n```\n\n## Demo\n\n### Playground\n\nTry character encoding conversion and detection directly in your browser.  \n[Open the Playground](https://polygonplanet.github.io/encoding.js/tests/playground.html)\n\n### Sample file encoding conversion demo\n\n[Try converting sample files encoded in Shift_JIS, EUC-JP, and other encodings](https://polygonplanet.github.io/encoding.js/tests/encoding-test.html)\n\n### User-selected file encoding conversion and detection demo\n\n[Try converting and detecting the character encoding of a selected file](https://polygonplanet.github.io/encoding.js/tests/detect-file-encoding.html)\n\n----\n\n## API\n\n* [detect](#encodingdetect-data-encodings)\n* [convert](#encodingconvert-data-to-from)\n* [urlEncode](#encodingurlencode-data)\n* [urlDecode](#encodingurldecode-string)\n* [base64Encode](#encodingbase64encode-data)\n* [base64Decode](#encodingbase64decode-string)\n* [codeToString](#encodingcodetostring-code)\n* [stringToCode](#encodingstringtocode-string)\n* [Japanese Zenkaku/Hankaku conversion](#japanese-zenkakuhankaku-conversion)\n\n----\n\n### Encoding.detect (data, [encodings])\n\nDetects the character encoding of the given data.\n\n#### Parameters\n\n* **data** *(Array\\<number\\>|TypedArray|Buffer|string)* : The code array or string to detect character encoding.\n* **\\[encodings\\]** *(string|Array\\<string\\>|Object)* : (Optional) Specifies a specific character encoding,\n  or an array of encodings to limit the detection. Detects automatically if this argument is omitted or `AUTO` is specified.\n  Supported encoding values can be found in the \"[Supported encodings](#supported-encodings)\" section.\n\n#### Return value\n\n*(string|boolean)*: Returns a string representing the detected encoding (e.g., `SJIS`, `UTF8`) listed in the \"[Supported encodings](#supported-encodings)\" section, or `false` if the encoding cannot be detected.\nIf the `encodings` argument is provided, it returns the name of the detected encoding if the `data` matches any of the specified encodings, or `false` otherwise.\n\n#### Examples\n\nExample of detecting character encoding.\n\n```javascript\nconst sjisArray = [130, 168, 130, 205, 130, 230]; // 'おはよ' array in SJIS\nconst detectedEncoding = Encoding.detect(sjisArray);\nconsole.log(`Encoding is ${detectedEncoding}`); // 'Encoding is SJIS'\n```\n\nExample of using the `encodings` argument to specify the character encoding to be detected.\nThis returns the detected encoding name if the specified encoding matches, or `false` otherwise:\n\n```javascript\nconst sjisArray = [130, 168, 130, 205, 130, 230]; // 'おはよ' array in SJIS\nconst detectedEncoding = Encoding.detect(sjisArray, 'SJIS');\nif (detectedEncoding) {\n  console.log('Encoding is SJIS');\n} else {\n  console.log('Encoding does not match SJIS');\n}\n```\n\nExample of specifying multiple encodings:\n\n```javascript\nconst sjisArray = [130, 168, 130, 205, 130, 230]; // 'おはよ' array in SJIS\nconst detectedEncoding = Encoding.detect(sjisArray, ['UTF8', 'SJIS']);\nif (detectedEncoding) {\n  console.log(`Encoding is ${detectedEncoding}`); // 'Encoding is SJIS'\n} else {\n  console.log('Encoding does not match UTF8 and SJIS');\n}\n```\n\n----\n\n### Encoding.convert (data, to[, from])\n\nConverts the character encoding of the given data.\n\n#### Parameters\n\n* **data** *(Array\\<number\\>|TypedArray|Buffer|string)* : The code array or string to be converted.\n* **to** *(string|Object)* : The character encoding name of the conversion destination as a string, or conversion options as an object.\n* **\\[from\\]** *(string|Array\\<string\\>)* : (Optional) The character encoding name of the conversion source as a string,\n  or an array of encoding names. Detects automatically if this argument is omitted or `AUTO` is specified.\n  Supported encoding values can be found in the \"[Supported encodings](#supported-encodings)\" section.\n\n#### Return value\n\n*(Array\\<number\\>|TypedArray|string)* : Returns a numeric character code array of the converted character encoding if `data` is an array or a buffer,\n or returns the converted string if `data` is a string.\n\n#### Examples\n\nExample of converting a character code array to Shift_JIS from UTF-8:\n\n```javascript\nconst utf8Array = [227, 129, 130]; // 'あ' in UTF-8\nconst sjisArray = Encoding.convert(utf8Array, 'SJIS', 'UTF8');\nconsole.log(sjisArray); // [130, 160] ('あ' in SJIS)\n```\n\nTyped arrays, such as `Uint8Array`, and Node.js `Buffer` objects can be passed in the same way:\n\n```javascript\nconst utf8Array = new Uint8Array([227, 129, 130]);\nconst sjisArray = Encoding.convert(utf8Array, 'SJIS', 'UTF8');\n```\n\nConverts character encoding by auto-detecting the encoding name of the source:\n\n```javascript\n// The character encoding is automatically detected when the argument `from` is omitted\nconst utf8Array = [227, 129, 130];\nlet sjisArray = Encoding.convert(utf8Array, 'SJIS');\n// You can also explicitly specify 'AUTO' to enable auto-detection\nsjisArray = Encoding.convert(utf8Array, 'SJIS', 'AUTO');\n```\n\n#### Specifying conversion options with an object\n\nFor readability, the second argument `to` can be passed as an options object.\nOptions such as `type`, `fallback`, and `bom` must be specified this way.\n\n```javascript\nconst utf8Array = [227, 129, 130];\nconst sjisArray = Encoding.convert(utf8Array, {\n  to: 'SJIS',\n  from: 'UTF8'\n});\n```\n\n#### Specify the return type by the `type` option\n\n`convert` returns an array by default, but you can change the return type by specifying the `type` option.\nIf `data` is a string and `type` is omitted, `type: 'string'` is assumed and the result is returned as a string.\n\n```javascript\nconst sjisArray = [130, 168, 130, 205, 130, 230]; // 'おはよ' array in SJIS\nconst unicodeString = Encoding.convert(sjisArray, {\n  to: 'UNICODE',\n  from: 'SJIS',\n  type: 'string' // Specify 'string' to return as string\n});\nconsole.log(unicodeString); // 'おはよ'\n```\n\nThe following `type` options are supported.\n\n* **string** : Return as a string.\n* **arraybuffer** : Return a `Uint16Array` (the option name is retained for historical reasons).\n* **array** : Return as an Array. (*default*)\n\n`type: 'string'` can be used as a shorthand for converting a code array to a string,\nas performed by [`Encoding.codeToString`](#encodingcodetostring-code).  \nNote: Specifying `type: 'string'` may not handle conversions properly, except when converting to `UNICODE`.\n\n#### Specify handling for unrepresentable characters\n\nWith the `fallback` option, you can specify how to handle characters that cannot be represented in the target encoding.\nThe `fallback` option supports the following values:\n\n* **html-entity**: Replace characters with HTML entities (decimal HTML numeric character references).\n* **html-entity-hex**: Replace characters with HTML entities (hexadecimal HTML numeric character references).\n* **ignore**: Ignore characters that cannot be represented.\n* **error**: Throw an error if any character cannot be represented.\n\n#### Replacing characters with HTML entities when they cannot be represented\n\nCharacters that cannot be represented in the target character set are replaced with '?' (U+003F) by default,\nbut by specifying `html-entity` as the `fallback` option, you can replace them with HTML entities (Numeric character references), such as `&#127843;`.\n\nExample of specifying `{ fallback: 'html-entity' }` option:\n\n```javascript\nconst unicodeArray = Encoding.stringToCode('寿司🍣ビール🍺');\n// No fallback specified\nlet sjisArray = Encoding.convert(unicodeArray, {\n  to: 'SJIS',\n  from: 'UNICODE'\n});\nconsole.log(sjisArray); // Converted to a code array of '寿司?ビール?'\n\n// Specify `fallback: html-entity`\nsjisArray = Encoding.convert(unicodeArray, {\n  to: 'SJIS',\n  from: 'UNICODE',\n  fallback: 'html-entity'\n});\nconsole.log(sjisArray); // Converted to a code array of '寿司&#127843;ビール&#127866;'\n```\n\nExample of specifying `{ fallback: 'html-entity-hex' }` option:\n\n```javascript\nconst unicodeArray = Encoding.stringToCode('ホッケの漢字は𩸽');\nconst sjisArray = Encoding.convert(unicodeArray, {\n  to: 'SJIS',\n  from: 'UNICODE',\n  fallback: 'html-entity-hex'\n});\nconsole.log(sjisArray); // Converted to a code array of 'ホッケの漢字は&#x29e3d;'\n```\n\n#### Ignoring characters when they cannot be represented\n\nBy specifying `ignore` as a `fallback` option, characters that cannot be represented in the target encoding format can be ignored.\n\nExample of specifying `{ fallback: 'ignore' }` option:\n\n```javascript\nconst unicodeArray = Encoding.stringToCode('寿司🍣ビール🍺');\n// No fallback specified\nlet sjisArray = Encoding.convert(unicodeArray, {\n  to: 'SJIS',\n  from: 'UNICODE'\n});\nconsole.log(sjisArray); // Converted to a code array of '寿司?ビール?'\n\n// Specify `fallback: ignore`\nsjisArray = Encoding.convert(unicodeArray, {\n  to: 'SJIS',\n  from: 'UNICODE',\n  fallback: 'ignore'\n});\nconsole.log(sjisArray); // Converted to a code array of '寿司ビール'\n```\n\n#### Throwing an Error when they cannot be represented\n\nIf you need to throw an error when a character cannot be represented in the target character encoding,\nspecify `error` as a `fallback` option. This will cause an exception to be thrown.\n\nExample of specifying `{ fallback: 'error' }` option:\n\n```javascript\nconst unicodeArray = Encoding.stringToCode('おにぎり🍙ラーメン🍜');\ntry {\n  const sjisArray = Encoding.convert(unicodeArray, {\n    to: 'SJIS',\n    from: 'UNICODE',\n    fallback: 'error' // Specify 'error' to throw an exception\n  });\n} catch (e) {\n  console.error(e); // Error: Character cannot be represented: [240, 159, 141, 153]\n}\n```\n\n#### Specify BOM in UTF-16\n\nYou can add a BOM (byte order mark) by specifying the `bom` option when converting to `UTF16`.\nThe default is no BOM.\n\n```javascript\nconst utf16Array = Encoding.convert(utf8Array, {\n  to: 'UTF16',\n  from: 'UTF8',\n  bom: true // Specify to add the BOM\n});\n```\n\nThe default byte order for `UTF16` is big-endian.\nIf you want to convert as little-endian, specify the `{ bom: 'LE' }` option.\n\n```javascript\nconst utf16leArray = Encoding.convert(utf8Array, {\n  to: 'UTF16',\n  from: 'UTF8',\n  bom: 'LE' // Specify to add the BOM as little-endian\n});\n```\n\nIf you do not need BOM, use `UTF16BE` or `UTF16LE`.\n`UTF16BE` is big-endian, and `UTF16LE` is little-endian, and both have no BOM.\n\n```javascript\nconst utf16beArray = Encoding.convert(utf8Array, {\n  to: 'UTF16BE',\n  from: 'UTF8'\n});\n```\n\n----\n\n### Encoding.urlEncode (data)\n\nEncodes a numeric character code array into a percent-encoded string formatted as a URI component in `%xx` format.\n\nurlEncode escapes all characters except the following, just like [`encodeURIComponent()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/encodeURIComponent).\n\n```\nA-Z a-z 0-9 - _ . ! ~ * ' ( )\n```\n\n#### Parameters\n\n* **data** *(Array\\<number\\>|TypedArray|Buffer|string)* : The numeric character code array or string that will be encoded into a percent-encoded URI component.\n\n#### Return value\n\n*(string)* : Returns a percent-encoded string formatted as a URI component in `%xx` format.\n\n#### Examples\n\nExample of URL encoding a Shift_JIS array:\n\n```javascript\nconst sjisArray = [130, 168, 130, 205, 130, 230]; // 'おはよ' array in SJIS\nconst encoded = Encoding.urlEncode(sjisArray);\nconsole.log(encoded); // '%82%A8%82%CD%82%E6'\n```\n\n----\n\n### Encoding.urlDecode (string)\n\nDecodes a percent-encoded string formatted as a URI component in `%xx` format to a numeric character code array.\n\n#### Parameters\n\n* **string** *(string)* : The string to decode.\n\n#### Return value\n\n*(Array\\<number\\>)* : Returns a numeric character code array.\n\n#### Examples\n\nExample of decoding a percent-encoded Shift_JIS string:\n\n```javascript\nconst encoded = '%82%A8%82%CD%82%E6'; // 'おはよ' encoded as percent-encoded SJIS string\nconst sjisArray = Encoding.urlDecode(encoded);\nconsole.log(sjisArray); // [130, 168, 130, 205, 130, 230]\n```\n\n----\n\n### Encoding.base64Encode (data)\n\nEncodes a numeric character code array into a Base64 encoded string.\n\n#### Parameters\n\n* **data** *(Array\\<number\\>|TypedArray|Buffer|string)* : The numeric character code array or string to encode.\n\n#### Return value\n\n*(string)* : Returns a Base64 encoded string.\n\n#### Examples\n\nExample of Base64 encoding a Shift_JIS array:\n\n```javascript\nconst sjisArray = [130, 168, 130, 205, 130, 230]; // 'おはよ' array in SJIS\nconst encodedStr = Encoding.base64Encode(sjisArray);\nconsole.log(encodedStr); // 'gqiCzYLm'\n```\n\n----\n\n### Encoding.base64Decode (string)\n\nDecodes a Base64 encoded string to a numeric character code array.\n\n#### Parameters\n\n* **string** *(string)* : The Base64 encoded string to decode.\n\n#### Return value\n\n*(Array\\<number\\>)* : Returns the decoded numeric character code array.\n\n#### Examples\n\nExample of `base64Encode` and `base64Decode`:\n\n```javascript\nconst sjisArray = [130, 177, 130, 241, 130, 201, 130, 191, 130, 205]; // 'こんにちは' array in SJIS\nconst encodedStr = Encoding.base64Encode(sjisArray);\nconsole.log(encodedStr); // 'grGC8YLJgr+CzQ=='\n\nconst decodedArray = Encoding.base64Decode(encodedStr);\nconsole.log(decodedArray); // [130, 177, 130, 241, 130, 201, 130, 191, 130, 205]\n```\n\n----\n\n### Encoding.codeToString (code)\n\nConverts a numeric character code array to a string.\n\n#### Parameters\n\n* **code** *(Array\\<number\\>|TypedArray|Buffer)* : The numeric character code array to convert.\n\n#### Return value\n\n*(string)* : Returns a converted string.\n\n#### Examples\n\nExample of converting a character code array to a string:\n\n```javascript\nconst sjisArray = [130, 168, 130, 205, 130, 230]; // 'おはよ' array in SJIS\nconst unicodeArray = Encoding.convert(sjisArray, {\n  to: 'UNICODE',\n  from: 'SJIS'\n});\nconst unicodeStr = Encoding.codeToString(unicodeArray);\nconsole.log(unicodeStr); // 'おはよ'\n```\n\n----\n\n### Encoding.stringToCode (string)\n\nConverts a string to a numeric character code array.\n\n#### Parameters\n\n* **string** *(string)* : The string to convert.\n\n#### Return value\n\n*(Array\\<number\\>)* : Returns a numeric character code array converted from the string.\n\n#### Examples\n\nExample of converting a string to a character code array:\n\n```javascript\nconst unicodeArray = Encoding.stringToCode('おはよ');\nconsole.log(unicodeArray); // [12362, 12399, 12424]\n```\n\n----\n\n### Japanese Zenkaku/Hankaku conversion\n\nThe following methods convert Japanese full-width (zenkaku) and half-width (hankaku) characters.\nThey accept either `UNICODE` strings or numeric arrays of `UNICODE` code units.\n\nReturns a converted string if the argument `data` is a string.\nReturns a numeric character code array if the argument `data` is a code array.\n\n- **Encoding.toHankakuCase (data)** : Converts full-width (zenkaku) symbols and alphanumeric characters to their half-width (hankaku) equivalents.\n- **Encoding.toZenkakuCase (data)** : Converts half-width (hankaku) symbols and alphanumeric characters to their full-width (zenkaku) equivalents.\n- **Encoding.toHiraganaCase (data)** : Converts full-width katakana to full-width hiragana.\n- **Encoding.toKatakanaCase (data)** : Converts full-width hiragana to full-width katakana.\n- **Encoding.toHankanaCase (data)** : Converts full-width katakana to half-width katakana.\n- **Encoding.toZenkanaCase (data)** : Converts half-width katakana to full-width katakana.\n- **Encoding.toHankakuSpace (data)** : Converts the ideographic space (U+3000) to an ASCII space (U+0020).\n- **Encoding.toZenkakuSpace (data)** : Converts an ASCII space (U+0020) to the ideographic space (U+3000).\n\n#### Parameters\n\n- **data** *(Array\\<number\\>|TypedArray|Buffer|string)* : The string or numeric character code array to convert.\n\n#### Return value\n\n*(Array\\<number\\>|string)* : Returns a converted string or numeric character code array.\n\n#### Examples\n\nExample of converting zenkaku and hankaku strings:\n\n```javascript\nconsole.log(Encoding.toHankakuCase('ａｂｃＤＥＦ１２３＠！＃＊＝')); // 'abcDEF123@!#*='\nconsole.log(Encoding.toZenkakuCase('abcDEF123@!#*=')); // 'ａｂｃＤＥＦ１２３＠！＃＊＝'\nconsole.log(Encoding.toHiraganaCase('アイウエオァィゥェォヴボポ')); // 'あいうえおぁぃぅぇぉゔぼぽ'\nconsole.log(Encoding.toKatakanaCase('あいうえおぁぃぅぇぉゔぼぽ')); // 'アイウエオァィゥェォヴボポ'\nconsole.log(Encoding.toHankanaCase('アイウエオァィゥェォヴボポ')); // 'ｱｲｳｴｵｧｨｩｪｫｳﾞﾎﾞﾎﾟ'\nconsole.log(Encoding.toZenkanaCase('ｱｲｳｴｵｧｨｩｪｫｳﾞﾎﾞﾎﾟ')); // 'アイウエオァィゥェォヴボポ'\nconsole.log(Encoding.toHankakuSpace('あいうえお　abc　123')); // 'あいうえお abc 123'\nconsole.log(Encoding.toZenkakuSpace('あいうえお abc 123')); // 'あいうえお　abc　123'\n```\n\nExample of converting zenkaku and hankaku code arrays:\n\n```javascript\nconst unicodeArray = Encoding.stringToCode('ａｂｃ１２３！＃　あいうアイウ ABCｱｲｳ');\nconsole.log(Encoding.codeToString(Encoding.toHankakuCase(unicodeArray)));\n// 'abc123!#　あいうアイウ ABCｱｲｳ'\nconsole.log(Encoding.codeToString(Encoding.toZenkakuCase(unicodeArray)));\n// 'ａｂｃ１２３！＃　あいうアイウ ＡＢＣｱｲｳ'\nconsole.log(Encoding.codeToString(Encoding.toHiraganaCase(unicodeArray)));\n// 'ａｂｃ１２３！＃　あいうあいう ABCｱｲｳ'\nconsole.log(Encoding.codeToString(Encoding.toKatakanaCase(unicodeArray)));\n// 'ａｂｃ１２３！＃　アイウアイウ ABCｱｲｳ'\nconsole.log(Encoding.codeToString(Encoding.toHankanaCase(unicodeArray)));\n// 'ａｂｃ１２３！＃　あいうｱｲｳ ABCｱｲｳ'\nconsole.log(Encoding.codeToString(Encoding.toZenkanaCase(unicodeArray)));\n// 'ａｂｃ１２３！＃　あいうアイウ ABCアイウ'\nconsole.log(Encoding.codeToString(Encoding.toHankakuSpace(unicodeArray)));\n// 'ａｂｃ１２３！＃ あいうアイウ ABCｱｲｳ'\nconsole.log(Encoding.codeToString(Encoding.toZenkakuSpace(unicodeArray)));\n// 'ａｂｃ１２３！＃　あいうアイウ　ABCｱｲｳ'\n```\n\n----\n\n## Other examples\n\n### Example using the `Fetch API` and Typed Arrays (Uint8Array)\n\nThis example reads a text file encoded in Shift_JIS as binary data,\nand displays it as a string after converting it to Unicode using [Encoding.convert](#encodingconvert-data-to-from).\n\n```javascript\n(async () => {\n  try {\n    const response = await fetch('shift_jis.txt');\n    const buffer = await response.arrayBuffer();\n\n    // Code array with Shift_JIS file contents\n    const sjisArray = new Uint8Array(buffer);\n\n    // Convert encoding to UNICODE (JavaScript Code Units) from Shift_JIS\n    const unicodeArray = Encoding.convert(sjisArray, {\n      to: 'UNICODE',\n      from: 'SJIS'\n    });\n\n    // Convert to string from code array for display\n    const unicodeString = Encoding.codeToString(unicodeArray);\n    console.log(unicodeString);\n  } catch (error) {\n    console.error('Error loading the file:', error);\n  }\n})();\n```\n\n<details>\n<summary>XMLHttpRequest version of this example</summary>\n\n```javascript\nconst req = new XMLHttpRequest();\nreq.open('GET', 'shift_jis.txt', true);\nreq.responseType = 'arraybuffer';\n\nreq.onload = (event) => {\n  const buffer = req.response;\n  if (buffer) {\n    // Code array with Shift_JIS file contents\n    const sjisArray = new Uint8Array(buffer);\n\n    // Convert encoding to UNICODE (JavaScript Code Units) from Shift_JIS\n    const unicodeArray = Encoding.convert(sjisArray, {\n      to: 'UNICODE',\n      from: 'SJIS'\n    });\n\n    // Convert to string from code array for display\n    const unicodeString = Encoding.codeToString(unicodeArray);\n    console.log(unicodeString);\n  }\n};\n\nreq.send(null);\n```\n</details>\n\n### Convert encoding for file using the File APIs\n\nThis example uses the File API to read the content of a selected file, detects its character encoding,\nand converts the file content to UNICODE from any character encoding such as `Shift_JIS` or `EUC-JP`.\nThe converted content is then displayed in a textarea.\n\n```html\n<input type=\"file\" id=\"file\">\n<div id=\"encoding\"></div>\n<textarea id=\"content\" rows=\"5\" cols=\"80\"></textarea>\n\n<script>\nfunction onFileSelect(event) {\n  const file = event.target.files[0];\n\n  const reader = new FileReader();\n  reader.onload = function(e) {\n    const codes = new Uint8Array(e.target.result);\n\n    const detectedEncoding = Encoding.detect(codes);\n    const encoding = document.getElementById('encoding');\n    encoding.textContent = `Detected encoding: ${detectedEncoding}`;\n\n    // Convert encoding to UNICODE\n    const unicodeString = Encoding.convert(codes, {\n      to: 'UNICODE',\n      from: detectedEncoding,\n      type: 'string'\n    });\n    document.getElementById('content').value = unicodeString;\n  };\n\n  reader.readAsArrayBuffer(file);\n}\n\ndocument.getElementById('file').addEventListener('change', onFileSelect);\n</script>\n```\n\n[**Demo**](https://polygonplanet.github.io/encoding.js/tests/detect-file-encoding.html)\n\n## Contributing\n\nWe welcome contributions from everyone.\nFor bug reports and feature requests, please [create an issue on GitHub](https://github.com/polygonplanet/encoding.js/issues).\n\n### Pull requests\n\nBefore submitting a pull request, please run `npm run test` to ensure there are no errors.\nWe only accept pull requests that pass all tests.\n\n## License\n\nThis project is licensed under the terms of the MIT license.\nSee the [LICENSE](LICENSE) file for details.\n","readmeFilename":"README.md"}