{"_id":"micromark-util-decode-string","_rev":"3759809","name":"micromark-util-decode-string","description":"micromark utility to decode markdown strings","dist-tags":{"latest":"2.0.1"},"maintainers":[{"name":"wooorm","email":"tituswormer@gmail.com"}],"time":{"modified":"2025-04-22T08:05:04.000Z","created":"2021-09-19T12:21:33.315Z","2.0.1":"2024-11-12T11:17:30.843Z","2.0.0":"2023-06-21T16:41:23.181Z","1.1.0":"2023-05-30T12:26:55.300Z","1.0.2":"2021-11-22T20:02:32.235Z","1.0.1":"2021-10-02T13:04:12.946Z","1.0.0":"2021-09-19T12:21:33.315Z"},"users":{},"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"repository":{"type":"git","url":"git+https://github.com/micromark/micromark.git#main"},"versions":{"2.0.1":{"name":"micromark-util-decode-string","version":"2.0.1","description":"micromark utility to decode markdown strings","license":"MIT","keywords":["micromark","util","utility","decode","character","reference","escape","string"],"repository":{"type":"git","url":"git+https://github.com/micromark/micromark.git#main"},"bugs":{"url":"https://github.com/micromark/micromark/issues"},"funding":[{"type":"GitHub Sponsors","url":"https://github.com/sponsors/unifiedjs"},{"type":"OpenCollective","url":"https://opencollective.com/unified"}],"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"}],"sideEffects":false,"type":"module","exports":{"development":"./dev/index.js","default":"./index.js"},"dependencies":{"micromark-util-character":"^2.0.0","micromark-util-decode-numeric-character-reference":"^2.0.0","micromark-util-symbol":"^2.0.0","decode-named-character-reference":"^1.0.0"},"scripts":{"build":"micromark-build"},"xo":{"envs":["shared-node-browser"],"prettier":true,"rules":{"unicorn/prefer-code-point":"off","unicorn/prefer-string-replace-all":"off"}},"_id":"micromark-util-decode-string@2.0.1","gitHead":"bcb6195e777f4109ddd2a20bbe0c24ec6fa369e9","types":"./index.d.ts","homepage":"https://github.com/micromark/micromark/tree/main#readme","_nodeVersion":"23.1.0","_npmVersion":"10.9.0","dist":{"shasum":"6cb99582e5d271e84efca8e61a807994d7161eb2","size":3799,"noattachment":false,"key":"/micromark-util-decode-string/-/micromark-util-decode-string-2.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/micromark-util-decode-string/download/micromark-util-decode-string-2.0.1.tgz"},"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"maintainers":[{"name":"wooorm","email":"tituswormer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/micromark-util-decode-string_2.0.1_1731410250627_0.012290891490968514"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-11-12T11:17:30.843Z","publish_time":1731410250843,"_source_registry_name":"default","_cnpm_publish_time":1731410250843},"2.0.0":{"name":"micromark-util-decode-string","version":"2.0.0","description":"micromark utility to decode markdown strings","license":"MIT","keywords":["micromark","util","utility","decode","character","reference","escape","string"],"repository":{"type":"git","url":"git+https://github.com/micromark/micromark.git#main"},"bugs":{"url":"https://github.com/micromark/micromark/issues"},"funding":[{"type":"GitHub Sponsors","url":"https://github.com/sponsors/unifiedjs"},{"type":"OpenCollective","url":"https://opencollective.com/unified"}],"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"}],"sideEffects":false,"type":"module","exports":{"development":"./dev/index.js","default":"./index.js"},"dependencies":{"micromark-util-character":"^2.0.0","micromark-util-decode-numeric-character-reference":"^2.0.0","micromark-util-symbol":"^2.0.0","decode-named-character-reference":"^1.0.0"},"scripts":{"build":"micromark-build"},"xo":false,"types":"./index.d.ts","gitHead":"31796dbdb5b2407d546f7ff77acd2db354c5bf94","homepage":"https://github.com/micromark/micromark/tree/main#readme","_id":"micromark-util-decode-string@2.0.0","_nodeVersion":"20.0.0","_npmVersion":"9.6.4","dist":{"shasum":"7dfa3a63c45aecaa17824e656bcdb01f9737154a","size":2801,"noattachment":false,"key":"/micromark-util-decode-string/-/micromark-util-decode-string-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/micromark-util-decode-string/download/micromark-util-decode-string-2.0.0.tgz"},"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"maintainers":[{"name":"wooorm","email":"tituswormer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/micromark-util-decode-string_2.0.0_1687365682998_0.02774104771453567"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-06-21T16:41:23.181Z","publish_time":1687365683181,"_source_registry_name":"default","_cnpm_publish_time":1687365683181},"1.1.0":{"name":"micromark-util-decode-string","version":"1.1.0","description":"micromark utility to decode markdown strings","license":"MIT","keywords":["micromark","util","utility","decode","character","reference","escape","string"],"repository":{"type":"git","url":"git+https://github.com/micromark/micromark.git#main"},"bugs":{"url":"https://github.com/micromark/micromark/issues"},"funding":[{"type":"GitHub Sponsors","url":"https://github.com/sponsors/unifiedjs"},{"type":"OpenCollective","url":"https://opencollective.com/unified"}],"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"}],"sideEffects":false,"type":"module","main":"index.js","types":"dev/index.d.ts","exports":{"types":"./dev/index.d.ts","development":"./dev/index.js","default":"./index.js"},"dependencies":{"micromark-util-character":"^1.0.0","micromark-util-decode-numeric-character-reference":"^1.0.0","micromark-util-symbol":"^1.0.0","decode-named-character-reference":"^1.0.0"},"scripts":{"build":"micromark-build"},"xo":false,"typeCoverage":{"atLeast":100,"detail":true,"strict":true,"ignoreCatch":true},"gitHead":"94b7679646bc0221899bba034f52f4abb3700f81","homepage":"https://github.com/micromark/micromark/tree/main#readme","_id":"micromark-util-decode-string@1.1.0","_nodeVersion":"20.0.0","_npmVersion":"9.6.4","dist":{"shasum":"dc12b078cba7a3ff690d0203f95b5d5537f2809c","size":2847,"noattachment":false,"key":"/micromark-util-decode-string/-/micromark-util-decode-string-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/micromark-util-decode-string/download/micromark-util-decode-string-1.1.0.tgz"},"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"maintainers":[{"name":"wooorm","email":"tituswormer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/micromark-util-decode-string_1.1.0_1685449615002_0.2636530649018378"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-05-30T12:26:55.300Z","publish_time":1685449615300,"_source_registry_name":"default","_cnpm_publish_time":1685449615300},"1.0.2":{"name":"micromark-util-decode-string","version":"1.0.2","description":"micromark utility to decode markdown strings","license":"MIT","keywords":["micromark","util","utility","decode","character","reference","escape","string"],"repository":{"type":"git","url":"git+https://github.com/micromark/micromark.git#main"},"bugs":{"url":"https://github.com/micromark/micromark/issues"},"funding":[{"type":"GitHub Sponsors","url":"https://github.com/sponsors/unifiedjs"},{"type":"OpenCollective","url":"https://opencollective.com/unified"}],"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"}],"sideEffects":false,"type":"module","main":"index.js","types":"dev/index.d.ts","exports":{"development":"./dev/index.js","default":"./index.js"},"dependencies":{"micromark-util-character":"^1.0.0","micromark-util-decode-numeric-character-reference":"^1.0.0","micromark-util-symbol":"^1.0.0","decode-named-character-reference":"^1.0.0"},"scripts":{"build":"rimraf \"*.d.ts\" \"{dev/,lib/}**/*.d.ts\" && tsc && micromark-build && type-coverage"},"xo":false,"typeCoverage":{"atLeast":100,"detail":true,"strict":true,"ignoreCatch":true},"gitHead":"048fed42f410d633be14ca0716ac53dd4ac1b3ec","homepage":"https://github.com/micromark/micromark/tree/main#readme","_id":"micromark-util-decode-string@1.0.2","_nodeVersion":"17.0.1","_npmVersion":"8.1.0","dist":{"shasum":"942252ab7a76dec2dbf089cc32505ee2bc3acf02","size":2347,"noattachment":false,"key":"/micromark-util-decode-string/-/micromark-util-decode-string-1.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/micromark-util-decode-string/download/micromark-util-decode-string-1.0.2.tgz"},"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"maintainers":[{"name":"wooorm","email":"tituswormer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/micromark-util-decode-string_1.0.2_1637611352055_0.4576036283497993"},"_hasShrinkwrap":false,"publish_time":1637611352235,"_cnpm_publish_time":1637611352235},"1.0.1":{"name":"micromark-util-decode-string","version":"1.0.1","description":"micromark utility to decode markdown strings","license":"MIT","keywords":["micromark","util","utility","decode","character","reference","escape","string"],"repository":{"type":"git","url":"git+https://github.com/micromark/micromark.git#main"},"bugs":{"url":"https://github.com/micromark/micromark/issues"},"funding":[{"type":"GitHub Sponsors","url":"https://github.com/sponsors/unifiedjs"},{"type":"OpenCollective","url":"https://opencollective.com/unified"}],"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"}],"sideEffects":false,"type":"module","main":"index.js","types":"dev/index.d.ts","exports":{"development":"./dev/index.js","default":"./index.js"},"dependencies":{"micromark-util-character":"^1.0.0","micromark-util-decode-numeric-character-reference":"^1.0.0","micromark-util-symbol":"^1.0.0","parse-entities":"^3.0.0"},"scripts":{"build":"rimraf \"*.d.ts\" \"{dev/,lib/}**/*.d.ts\" && tsc && micromark-build && type-coverage"},"xo":false,"typeCoverage":{"atLeast":100,"detail":true,"strict":true,"ignoreCatch":true},"gitHead":"b91e05f720fc2ded2491598bd4d500db9a376498","homepage":"https://github.com/micromark/micromark/tree/main#readme","_id":"micromark-util-decode-string@1.0.1","_nodeVersion":"16.9.0","_npmVersion":"7.23.0","dist":{"shasum":"fa779dcef7f2dc2c9e4b759abd85e553674eea4f","size":2352,"noattachment":false,"key":"/micromark-util-decode-string/-/micromark-util-decode-string-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/micromark-util-decode-string/download/micromark-util-decode-string-1.0.1.tgz"},"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"maintainers":[{"name":"wooorm","email":"tituswormer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/micromark-util-decode-string_1.0.1_1633179852806_0.3860847984806386"},"_hasShrinkwrap":false,"publish_time":1633179852946,"_cnpm_publish_time":1633179852946},"1.0.0":{"name":"micromark-util-decode-string","version":"1.0.0","description":"micromark utility to decode markdown strings","license":"MIT","keywords":["micromark","util","utility","decode","character","reference","escape","string"],"repository":{"type":"git","url":"git+https://github.com/micromark/micromark.git#main"},"bugs":{"url":"https://github.com/micromark/micromark/issues"},"funding":[{"type":"GitHub Sponsors","url":"https://github.com/sponsors/unifiedjs"},{"type":"OpenCollective","url":"https://opencollective.com/unified"}],"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"}],"sideEffects":false,"type":"module","main":"index.js","types":"dev/index.d.ts","exports":{"development":"./dev/index.js","default":"./index.js"},"dependencies":{"micromark-util-character":"^1.0.0","micromark-util-decode-numeric-character-reference":"^1.0.0","parse-entities":"^3.0.0"},"scripts":{"build":"rimraf \"*.d.ts\" \"{dev/,lib/}**/*.d.ts\" && tsc && micromark-build && type-coverage"},"xo":false,"typeCoverage":{"atLeast":100,"detail":true,"strict":true,"ignoreCatch":true},"gitHead":"4ebefb0d7ae8176c593e2bdc98a0d9e4d3737bd1","homepage":"https://github.com/micromark/micromark/tree/main#readme","_id":"micromark-util-decode-string@1.0.0","_nodeVersion":"16.9.0","_npmVersion":"7.23.0","dist":{"shasum":"f97946825231d9c97df767875064401774578a6e","size":2348,"noattachment":false,"key":"/micromark-util-decode-string/-/micromark-util-decode-string-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/micromark-util-decode-string/download/micromark-util-decode-string-1.0.0.tgz"},"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"maintainers":[{"name":"wooorm","email":"tituswormer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/micromark-util-decode-string_1.0.0_1632054093181_0.4754689675542516"},"_hasShrinkwrap":false,"publish_time":1632054093315,"_cnpm_publish_time":1632054093315}},"readme":"# micromark-util-decode-string\n\n[![Build][build-badge]][build]\n[![Coverage][coverage-badge]][coverage]\n[![Downloads][downloads-badge]][downloads]\n[![Size][bundle-size-badge]][bundle-size]\n[![Sponsors][sponsors-badge]][opencollective]\n[![Backers][backers-badge]][opencollective]\n[![Chat][chat-badge]][chat]\n\n[micromark][] utility to decode markdown strings.\n\n## Contents\n\n* [What is this?](#what-is-this)\n* [When should I use this?](#when-should-i-use-this)\n* [Install](#install)\n* [Use](#use)\n* [API](#api)\n  * [`decodeString(value)`](#decodestringvalue)\n* [Types](#types)\n* [Compatibility](#compatibility)\n* [Security](#security)\n* [Contribute](#contribute)\n* [License](#license)\n\n## What is this?\n\nThis package exposes an algorithm to parse character escapes and character\nreferences.\n\n## When should I use this?\n\nThis package might be useful when you are making your own micromark extensions.\n\n## Install\n\nThis package is [ESM only][esm].\nIn Node.js (version 16+), install with [npm][]:\n\n```sh\nnpm install micromark-util-decode-string\n```\n\nIn Deno with [`esm.sh`][esmsh]:\n\n```js\nimport {decodeString} from 'https://esm.sh/micromark-util-decode-string@1'\n```\n\nIn browsers with [`esm.sh`][esmsh]:\n\n```html\n<script type=\"module\">\n  import {decodeString} from 'https://esm.sh/micromark-util-decode-string@1?bundle'\n</script>\n```\n\n## Use\n\n```js\nimport {decodeString} from 'micromark-util-decode-string'\n\ndecodeString('a &semi; b') // 'a ; b'\ndecodeString('a \\\\; b') // 'a ; b'\ndecodeString('a ; b') // 'a ; b'\n```\n\n## API\n\nThis module exports the identifier [`decodeString`][api-decode-string].\nThere is no default export.\n\n### `decodeString(value)`\n\nDecode markdown strings (which occur in places such as fenced code info strings,\ndestinations, labels, and titles).\n\nThe “string” content type allows character escapes and -references.\nThis decodes those.\n\n###### Parameters\n\n* `value` (`string`)\n  — value to decode\n\n###### Returns\n\nDecoded value (`string`).\n\n## Types\n\nThis package is fully typed with [TypeScript][].\nIt exports no additional types.\n\n## Compatibility\n\nProjects maintained by the unified collective are compatible with maintained\nversions of Node.js.\n\nWhen we cut a new major release, we drop support for unmaintained versions of\nNode.\nThis means we try to keep the current release line,\n`micromark-util-decode-string@2`, compatible with Node.js 16.\nThis package works with `micromark@3`.\n\n## Security\n\nThis package is safe.\nSee [`security.md`][securitymd] in [`micromark/.github`][health] for how to\nsubmit a security report.\n\n## Contribute\n\nSee [`contributing.md`][contributing] in [`micromark/.github`][health] for ways\nto get started.\nSee [`support.md`][support] for ways to get help.\n\nThis project has a [code of conduct][coc].\nBy interacting with this repository, organisation, or community you agree to\nabide by its terms.\n\n## License\n\n[MIT][license] © [Titus Wormer][author]\n\n<!-- Definitions -->\n\n[build-badge]: https://github.com/micromark/micromark/workflows/main/badge.svg\n\n[build]: https://github.com/micromark/micromark/actions\n\n[coverage-badge]: https://img.shields.io/codecov/c/github/micromark/micromark.svg\n\n[coverage]: https://codecov.io/github/micromark/micromark\n\n[downloads-badge]: https://img.shields.io/npm/dm/micromark-util-normalize-identifier.svg\n\n[downloads]: https://www.npmjs.com/package/micromark-util-normalize-identifier\n\n[bundle-size-badge]: https://img.shields.io/badge/dynamic/json?label=minzipped%20size&query=$.size.compressedSize&url=https://deno.bundlejs.com/?q=micromark-util-normalize-identifier\n\n[bundle-size]: https://bundlejs.com/?q=micromark-util-normalize-identifier\n\n[sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg\n\n[backers-badge]: https://opencollective.com/unified/backers/badge.svg\n\n[opencollective]: https://opencollective.com/unified\n\n[npm]: https://docs.npmjs.com/cli/install\n\n[esm]: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c\n\n[esmsh]: https://esm.sh\n\n[chat-badge]: https://img.shields.io/badge/chat-discussions-success.svg\n\n[chat]: https://github.com/micromark/micromark/discussions\n\n[license]: https://github.com/micromark/micromark/blob/main/license\n\n[author]: https://wooorm.com\n\n[health]: https://github.com/micromark/.github\n\n[securitymd]: https://github.com/micromark/.github/blob/main/security.md\n\n[contributing]: https://github.com/micromark/.github/blob/main/contributing.md\n\n[support]: https://github.com/micromark/.github/blob/main/support.md\n\n[coc]: https://github.com/micromark/.github/blob/main/code-of-conduct.md\n\n[typescript]: https://www.typescriptlang.org\n\n[micromark]: https://github.com/micromark/micromark\n\n[api-decode-string]: #decodestringvalue\n","_attachments":{},"homepage":"https://github.com/micromark/micromark/tree/main#readme","bugs":{"url":"https://github.com/micromark/micromark/issues"},"license":"MIT"}