{"_id":"@bojtosvivi/iso-8859-2","_rev":"1-51f226b45853d39bf7ff2293d0e616e4","name":"@bojtosvivi/iso-8859-2","dist-tags":{"latest":"3.0.6"},"versions":{"3.0.5":{"name":"@bojtosvivi/iso-8859-2","version":"3.0.5","description":"A robust iso-8859-2 encoder/decoder written in JavaScript.","homepage":"https://mths.be/iso-8859-2","exports":"./iso-8859-2.mjs","keywords":["codec","decoder","decoding","encoder","encoding","legacy","legacy-encoding","csisolatin2","iso-8859-2","iso-ir-101","iso8859-2","iso88592","iso_8859-2","iso_8859-2:1987","l2","latin2"],"license":"MIT","author":{"name":"Mathias Bynens","url":"https://mathiasbynens.be/"},"repository":{"type":"git","url":"git+https://github.com/mathiasbynens/iso-8859-2.git"},"bugs":{"url":"https://github.com/mathiasbynens/iso-8859-2/issues"},"types":"iso-8859-2.d.ts","scripts":{"download":"curl https://encoding.spec.whatwg.org/index-iso-8859-2.txt > data/index.txt","build":"node scripts/transform-data.js","test":"node tests/tests.mjs","cover":"istanbul cover --report html --verbose --dir coverage tests/tests.mjs"},"devDependencies":{"istanbul":"^0.4.2","jsesc":"^3.0.2","lodash.template":"^4.5.0"},"gitHead":"f0094359fe1fe6fef0ea06e6b6b0af9808450d8a","_id":"@bojtosvivi/iso-8859-2@3.0.5","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-rDskSt0iBVTKD6ZVm0C+qFCF4uXjTmDa7WdfLDB6IFIdd3ebKVIWA5KvG7mLFXPiDadL3nQ8ulzoq3aeIpMyAQ==","shasum":"678a2547cd5b0f612472f04877d2aebf24856e2f","tarball":"https://registry.npmjs.org/@bojtosvivi/iso-8859-2/-/iso-8859-2-3.0.5.tgz","fileCount":5,"unpackedSize":12698,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAoUdXdHU2/MBRgtemkljz8X0fgLih6oazvA0/ojxbeKAiB/dSonzakyZGAvp3Q4YmR69HwWkNLuteF02427Ruo/Fg=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj3OOVACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmomoQ//XjdHcVYsI0l7OrZTI6JHQEkVyn1KAWDk4yV1SJLakh76pbmC\r\n3N3IEsagobik+tEyktc1ooHQPvJUjoAIt9ifhLlhN2OuqGb8InDonjCu88Ax\r\nR5oozgwncmgppmglPW7vY0UJN1FSKvMSiIi6g3AMPjRT8yYvL/cb2elX2dSg\r\nhjNP8h8uSlmYbCKuxWnHJ610HpbvDg7f/mqLNInJ2VN7qEouztqg53pM9+p7\r\nKKqnvqz6oWzm3E5BAfsGidkNNVtXNzkh+ZRHD7L9iciEgL9FGTy7ffiFfBaH\r\nhoGZKO7i2/DJLeRB5o52JnTpKnjd/0xo8+lJYchQdbIthJv6AnLCK+zwkw1K\r\nYAGX3rGwEF/mQX/p7tk5e4QiqTQwifRqtdmORWhPJzk9OKr3vEQ7mwa9itBd\r\nga0QrUQ8Mn2EPVbqxWLRuaAaDe7P7u6b7RxHPkiXpnH0yg0Bnp8kmj11diLv\r\nYKiVEKaWiivZj4vdhq9yJUXlmmp7hlsU234mQaCv7FZIMbthgd6KryyqGFb/\r\nywKYEkkebqH2+d+wxBstCg1T3iAdEcRGS9qTOnMPB62bUKZrMBCAty4AWSQh\r\nT288NiduTFRG/3qmC9C95g9OUCPE/wVNm8P+tcoYVG79vpv7gUo6Z9fkwTms\r\ng7O7S3/C4FjpiD9Upy0YFDjBJtiwfae4OYA=\r\n=jMAS\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bojtosvivi","email":"bojtosvivi@gmail.com"},"directories":{},"maintainers":[{"name":"bojtosvivi","email":"bojtosvivi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/iso-8859-2_3.0.5_1675420565603_0.5031784832840696"},"_hasShrinkwrap":false},"3.0.6":{"name":"@bojtosvivi/iso-8859-2","version":"3.0.6","description":"A robust iso-8859-2 encoder/decoder written in JavaScript.","homepage":"https://mths.be/iso-8859-2","exports":"./iso-8859-2.mjs","keywords":["codec","decoder","decoding","encoder","encoding","legacy","legacy-encoding","csisolatin2","iso-8859-2","iso-ir-101","iso8859-2","iso88592","iso_8859-2","iso_8859-2:1987","l2","latin2"],"license":"MIT","author":{"name":"Mathias Bynens","url":"https://mathiasbynens.be/"},"repository":{"type":"git","url":"git+https://github.com/mathiasbynens/iso-8859-2.git"},"bugs":{"url":"https://github.com/mathiasbynens/iso-8859-2/issues"},"types":"iso-8859-2.d.ts","scripts":{"download":"curl https://encoding.spec.whatwg.org/index-iso-8859-2.txt > data/index.txt","build":"node scripts/transform-data.js","test":"node tests/tests.mjs","cover":"istanbul cover --report html --verbose --dir coverage tests/tests.mjs"},"devDependencies":{"istanbul":"^0.4.2","jsesc":"^3.0.2","lodash.template":"^4.5.0"},"gitHead":"a742503230c5ed7f21539dfca7e82a9e00ab9c25","_id":"@bojtosvivi/iso-8859-2@3.0.6","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-X/z6vmzBArVSHSK3wj3DWDe68GDRISaP6Jcq8wc6TzNx8lQ8PXaQV4cl7Z14ZSgYpegVQGwPaty/qYTZgLNQuQ==","shasum":"2923455af1013e830299345bc75d04a837ace9e5","tarball":"https://registry.npmjs.org/@bojtosvivi/iso-8859-2/-/iso-8859-2-3.0.6.tgz","fileCount":5,"unpackedSize":12710,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBMeChL/k3AP8CWY6pXDp//F0QbcBOVOPt7z20+ojcS+AiBktBTtXiHybJ4owBTVCNwi32QCOqlsrI6RUT78qR671w=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj3OWuACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoG0xAAi2RHm930Z3Dn2rudE4Xi9q9HNfQw7/F318wvyyq5EfCNZ3wE\r\nNkN0r7RWNK6gzrjAmzXcQv76XeQnto5D2RSr2Ft6iKJkIOpyjFevaKrc5xj9\r\n1bjcy2/y1uKebN3a8QkBktHYbLC3zuiP3qq2UMeAoUHdFxVrvjFBed/STka3\r\njASAfoKazdDfTeb31vcFLa4YGPV6Vau9xabLRxj3YnS88k7RZYSw+V+5o3pc\r\nn/ymTk2AQWHhim1tbbOrzgckR9MHix/WZJO7cyzAU5D+A5UicLZu/MbiZMjD\r\nBbS1tff33Mbb1ZZpYqcyp1Sa2Wb5EGcRHDL6eDCZFMeYYiKzFJPInGCmhFcP\r\ncWnWxchEx0bUdS+G/rLAmbnpFcJUcd9N6pFt3d6Xlew2lzyWLKLu1FutLyxc\r\nzpEZQYMbizxckhVkVMAwjjkW1W6REFmir/ie2VCa+m5dTDqeosxRztUnu93O\r\nonMF15v8eoKsq8bQ2mpM+iCN8nrdPdxkADvT2uQ1ks13X62SQWBmnaDbdfyR\r\nv7N5LocN61UAcpzOBLOuAtIY8AZd9BgTzntf687bJvFk4+JbU0qbHWQ8JCEs\r\nMhstwZ7HHjMtJnj5HFSl7HutBp+amMRCK/JoVQee7jx5Gb1Fe3w6+oDQKfnY\r\nKg9XTeo7df/FM/m4rxRPfRY/qBGjJa3bbYU=\r\n=VrXc\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bojtosvivi","email":"bojtosvivi@gmail.com"},"directories":{},"maintainers":[{"name":"bojtosvivi","email":"bojtosvivi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/iso-8859-2_3.0.6_1675421102305_0.851315836589043"},"_hasShrinkwrap":false}},"time":{"created":"2023-02-03T10:36:05.538Z","3.0.5":"2023-02-03T10:36:05.788Z","modified":"2023-02-03T10:45:02.603Z","3.0.6":"2023-02-03T10:45:02.486Z"},"maintainers":[{"name":"bojtosvivi","email":"bojtosvivi@gmail.com"}],"description":"A robust iso-8859-2 encoder/decoder written in JavaScript.","homepage":"https://mths.be/iso-8859-2","keywords":["codec","decoder","decoding","encoder","encoding","legacy","legacy-encoding","csisolatin2","iso-8859-2","iso-ir-101","iso8859-2","iso88592","iso_8859-2","iso_8859-2:1987","l2","latin2"],"repository":{"type":"git","url":"git+https://github.com/mathiasbynens/iso-8859-2.git"},"author":{"name":"Mathias Bynens","url":"https://mathiasbynens.be/"},"bugs":{"url":"https://github.com/mathiasbynens/iso-8859-2/issues"},"license":"MIT","readme":"# iso-8859-2 [![Build status](https://github.com/mathiasbynens/iso-8859-2/workflows/run-checks/badge.svg)](https://github.com/mathiasbynens/iso-8859-2/actions?query=workflow%3Arun-checks) [![iso-8859-2 on npm](https://img.shields.io/npm/v/iso-8859-2)](https://www.npmjs.com/package/iso-8859-2)\n\n_iso-8859-2_ is a robust JavaScript implementation of [the iso-8859-2 character encoding as defined by the Encoding Standard](https://encoding.spec.whatwg.org/#iso-8859-2).\n\nThis encoding is known under the following names: csisolatin2, iso-8859-2, iso-ir-101, iso8859-2, iso88592, iso_8859-2, iso_8859-2:1987, l2, and latin2.\n\n## Installation\n\nVia [npm](https://www.npmjs.com/):\n\n```bash\nnpm install iso-8859-2\n```\n\nIn a browser or in [Node.js](https://nodejs.org/):\n\n```js\nimport {encode, decode, labels} from 'iso-8859-2';\n// or…\nimport * as iso88592 from 'iso-8859-2';\n```\n\n## API\n\n### `iso88592.labels`\n\nAn array of strings, each representing a [label](https://encoding.spec.whatwg.org/#label) for this encoding.\n\n### `iso88592.encode(input, options)`\n\nThis function takes a plain text string (the `input` parameter) and encodes it according to iso-8859-2. The return value is an environment-agnostic `Uint16Array` of which each element represents an octet as per iso-8859-2.\n\n```js\nconst encodedData = iso88592.encode(text);\n```\n\nThe optional `options` object and its `mode` property can be used to set the error mode. The two available error modes are `'fatal'` (the default) or `'replacement'`. (Note: This differs from [the spec](https://encoding.spec.whatwg.org/#error-mode), which recognizes “fatal” and HTML” modes for encoders. The reason behind this difference is that the spec algorithm is aimed at producing HTML, whereas this library encodes into an environment-agnostic `Uint16Array` of bytes.)\n\n```js\nconst encodedData = iso88592.encode(text, {\n  mode: 'replacement'\n});\n// If `text` contains a symbol that cannot be represented in iso-8859-2,\n// instead of throwing an error, it becomes 0xFFFD.\n```\n\n### `iso88592.decode(input, options)`\n\nThis function decodes `input` according to iso-8859-2. The `input` parameter can either be a `Uint16Array` of which each element represents an octet as per iso-8859-2, or a ‘byte string’ (i.e. a string of which each item represents an octet as per iso-8859-2).\n\n```js\nconst text = iso88592.decode(encodedData);\n```\n\nThe optional `options` object and its `mode` property can be used to set the [error mode](https://encoding.spec.whatwg.org/#error-mode). For decoding, the error mode can be `'replacement'` (the default) or `'fatal'`.\n\n```js\nconst text = iso88592.decode(encodedData, {\n  mode: 'fatal'\n});\n// If `encodedData` contains an invalid byte for the iso-8859-2 encoding,\n// instead of replacing it with U+FFFD in the output, an error is thrown.\n```\n\n## Notes\n\n[Similar modules for other single-byte legacy encodings are available.](https://www.npmjs.com/browse/keyword/legacy-encoding)\n\n## Author\n\n| [![twitter/mathias](https://gravatar.com/avatar/24e08a9ea84deb17ae121074d0f17125?s=70)](https://twitter.com/mathias \"Follow @mathias on Twitter\") |\n|---|\n| [Mathias Bynens](https://mathiasbynens.be/) |\n\n## License\n\n_iso-8859-2_ is available under the [MIT](https://mths.be/mit) license.\n","readmeFilename":"README.md"}