{"_id":"remend","_rev":"13-2b19fef37c063d830cde0dc04dc816b1","name":"remend","dist-tags":{"canary":"1.0.2-canary.0","latest":"1.3.1"},"versions":{"0.0.0":{"name":"remend","version":"0.0.0","author":"","license":"ISC","_id":"remend@0.0.0","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"dist":{"shasum":"233b8d86cdc6ce6cc507cfd568b12abb8fe3a271","tarball":"https://registry.npmjs.org/remend/-/remend-0.0.0.tgz","fileCount":1,"integrity":"sha512-EDANSLdZQcog8+SfQkeNbo5s+DXgk9RK0/EAgyNyXZpIYwzKcAyJ+0ZfsUYQiWnAE7Wa9ygsOtsp2OtZs59aVw==","signatures":[{"sig":"MEUCIQDIR8MSbWOuLn7KDZ5BMqIxDl5M/bQIlTGvIgamDCgszgIgMqu4/QpJ1iyOVZ6//Iv1xhEp9QAIE0SMKwAIN6sEf2s=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":202},"main":"index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"haydenbleasel","email":"hello@haydenbleasel.com"},"_npmVersion":"10.9.4","description":"","directories":{},"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/remend_0.0.0_1764746035636_0.48214830180881596","host":"s3://npm-registry-packages-npm-production"}},"0.0.1":{"name":"remend","version":"0.0.1","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@0.0.1","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"0f4d3c8466ff35b36c46d9b6f5bbc2f48c0446ad","tarball":"https://registry.npmjs.org/remend/-/remend-0.0.1.tgz","fileCount":6,"integrity":"sha512-jGOM2soGz1WDUpOShfFEqkKgUEqnTeVc7uuncHQsdURwcLReukvrhaZlJz78DDLKls4XKK4DTMGFcqtwekglUw==","signatures":[{"sig":"MEUCIFqmNOvr1VLbLo0u+njb2SnzLef1dUP0rTjKfJQijNZpAiEAmWb+d5v/mVv79tYuGVqN4nfoBE5qPPjbyqEywGZvMiU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":15151},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"0e92bd5fddfeb835f198383115b645a30acef8cf","scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"haydenbleasel","email":"hello@haydenbleasel.com"},"repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"10.9.4","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"22.21.1","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.0","vitest":"^3.2.4","@vitest/coverage-v8":"^3.2.4"},"peerDependencies":{},"_npmOperationalInternal":{"tmp":"tmp/remend_0.0.1_1764789120610_0.37642108504050653","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"remend","version":"1.0.1","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.0.1","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"1fc520964cb88131d3559cc8d349c02e11352235","tarball":"https://registry.npmjs.org/remend/-/remend-1.0.1.tgz","fileCount":7,"integrity":"sha512-152puVH0qMoRJQFnaMG+rVDdf01Jq/CaED+MBuXExurJgdbkLp0c3TIe4R12o28Klx8uyGsjvFNG05aFG69G9w==","signatures":[{"sig":"MEYCIQCcd/yXCRiQO7HdPVyELr0gfwiNAUWRGDIRwjad0IyGrAIhAN2k0poLsxp8AX39cnV/TV1GZhvMrv8ZrmQ9qRa6Y0I+","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":15702},"main":"./dist/index.js","type":"module","_from":"file:remend-1.0.1.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"haydenbleasel","email":"hello@haydenbleasel.com"},"_resolved":"/tmp/f672c2210ccfa4e70e9b7de4a745c4f6/remend-1.0.1.tgz","_integrity":"sha512-152puVH0qMoRJQFnaMG+rVDdf01Jq/CaED+MBuXExurJgdbkLp0c3TIe4R12o28Klx8uyGsjvFNG05aFG69G9w==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"10.9.4","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"22.21.1","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.0","vitest":"^3.2.4","@vitest/coverage-v8":"^3.2.4"},"peerDependencies":{},"_npmOperationalInternal":{"tmp":"tmp/remend_1.0.1_1764790546095_0.4535925332979407","host":"s3://npm-registry-packages-npm-production"}},"1.0.2-canary.0":{"name":"remend","version":"1.0.2-canary.0","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.0.2-canary.0","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"6cf8f54390461795e38cd3fdfb6f4fd2f845a5d8","tarball":"https://registry.npmjs.org/remend/-/remend-1.0.2-canary.0.tgz","fileCount":7,"integrity":"sha512-B6H4NqO0YtrMFZyvsIwI5SoAOHsEQwmbN/JAub2NApFQv39n43fE82d5Jg9DPcRPHiAadkSwZDwlhH++Ww4NXw==","signatures":[{"sig":"MEUCICF2+iLPSb3a1oJirQjSSWsInSeZDuXvTCjKp/0OUSM5AiEAl4MSWO5JBtI/BY9LXJFV9FkGBnDikfaV4vrcHrejcR0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":22852},"main":"./dist/index.js","type":"module","_from":"file:remend-1.0.2-canary.0.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"haydenbleasel","email":"hello@haydenbleasel.com"},"_resolved":"/private/var/folders/4g/dvkl_2k561g8sh4dcnhg6fm00000gn/T/a08b46b4811b1e5b4f7059b3b3bc52e9/remend-1.0.2-canary.0.tgz","_integrity":"sha512-B6H4NqO0YtrMFZyvsIwI5SoAOHsEQwmbN/JAub2NApFQv39n43fE82d5Jg9DPcRPHiAadkSwZDwlhH++Ww4NXw==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"11.6.2","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"24.11.1","dependencies":{},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"tsup":"^8.5.1","vitest":"^4.0.15","@vitest/coverage-v8":"^4.0.15"},"peerDependencies":{},"_npmOperationalInternal":{"tmp":"tmp/remend_1.0.2-canary.0_1767735775133_0.9864317480885361","host":"s3://npm-registry-packages-npm-production"}},"1.0.2":{"name":"remend","version":"1.0.2","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.0.2","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"fc023e2b1ee84d066008199d5b05dc96396de314","tarball":"https://registry.npmjs.org/remend/-/remend-1.0.2.tgz","fileCount":7,"integrity":"sha512-Kcr8qu3OcfX9pjVjzj3KC1B7jVZKofQzX1UEQ5W5LPS/pFTgOjF58zDBgdi6NDw86Ro8vOS0S0Yyf9r7CprmGg==","signatures":[{"sig":"MEUCIQD/AoDbaq9ErAeII1fJWaRdVMD7f3uAJP1fLJCiLnWUFQIgX87l+EXzveNeVajEsevUqLjA9ekCLXCqWlAGTqCyF00=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/remend@1.0.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":22847},"main":"./dist/index.js","type":"module","_from":"file:remend-1.0.2.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0a5720a0-8248-44a7-b3c7-57ce34ec0043"}},"_resolved":"/tmp/c83f11562f589d77214c12ef8c9c81d8/remend-1.0.2.tgz","_integrity":"sha512-Kcr8qu3OcfX9pjVjzj3KC1B7jVZKofQzX1UEQ5W5LPS/pFTgOjF58zDBgdi6NDw86Ro8vOS0S0Yyf9r7CprmGg==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"11.7.0","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"24.12.0","dependencies":{},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1","vitest":"^4.0.15","@vitest/coverage-v8":"^4.0.15"},"peerDependencies":{},"_npmOperationalInternal":{"tmp":"tmp/remend_1.0.2_1768193026197_0.49170762094556375","host":"s3://npm-registry-packages-npm-production"}},"1.1.0":{"name":"remend","version":"1.1.0","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.1.0","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"2a7199b82860f44bfcb7d8a4c88ade596ded7aed","tarball":"https://registry.npmjs.org/remend/-/remend-1.1.0.tgz","fileCount":7,"integrity":"sha512-JENGyuIhTwzUfCarW43X4r9cehoqTo9QyYxfNDZSud2AmqeuWjZ5pfybasTa4q0dxTJAj5m8NB+wR+YueAFpxQ==","signatures":[{"sig":"MEUCIQD+GGBiXdQmqh88vJ7QUuwDAWhlCJxTI4Es0ZpVnZBpPwIgJf7P32+XasqwptM0CC46BT1T0V6PJYnvL64VOa0J1+M=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/remend@1.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":32500},"main":"./dist/index.js","type":"module","_from":"file:remend-1.1.0.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0a5720a0-8248-44a7-b3c7-57ce34ec0043"}},"_resolved":"/tmp/e34c64bceabd7e7f0f75b3934441b96c/remend-1.1.0.tgz","_integrity":"sha512-JENGyuIhTwzUfCarW43X4r9cehoqTo9QyYxfNDZSud2AmqeuWjZ5pfybasTa4q0dxTJAj5m8NB+wR+YueAFpxQ==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"11.7.0","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"24.12.0","_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1","vitest":"^4.0.15","@vitest/coverage-v8":"^4.0.15","mdast-util-from-markdown":"^2.0.2"},"_npmOperationalInternal":{"tmp":"tmp/remend_1.1.0_1768799361922_0.06584696729049555","host":"s3://npm-registry-packages-npm-production"}},"1.2.0":{"name":"remend","version":"1.2.0","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.2.0","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"c203cfa395b6bd43157b756f0526b85bac366bc7","tarball":"https://registry.npmjs.org/remend/-/remend-1.2.0.tgz","fileCount":5,"integrity":"sha512-NbKrdWweTRuByPYErzQCNpNtsR9M1QQ0hK2UzmnmlSaEqHnkQ5Korlyi8KpdbOJ0rImJfRy4EAY0uDxYnL9Plw==","signatures":[{"sig":"MEUCICfnsbKvGSvMT2lQZUNVsfwUXwmWOUzDqJTkjRUNNWlVAiEAl9DChBLtcMiF2788kvyZxwvFY87o47EnCwoBQAEIspE=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/remend@1.2.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":21140},"main":"./dist/index.js","type":"module","_from":"file:remend-1.2.0.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0a5720a0-8248-44a7-b3c7-57ce34ec0043"}},"_resolved":"/tmp/74ad4cf7eb502ffabf71f1665394cac5/remend-1.2.0.tgz","_integrity":"sha512-NbKrdWweTRuByPYErzQCNpNtsR9M1QQ0hK2UzmnmlSaEqHnkQ5Korlyi8KpdbOJ0rImJfRy4EAY0uDxYnL9Plw==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"11.9.0","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"24.13.0","_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1","vitest":"^4.0.15","@vitest/coverage-v8":"^4.0.15","mdast-util-from-markdown":"^2.0.2"},"_npmOperationalInternal":{"tmp":"tmp/remend_1.2.0_1770658291763_0.05286293906517736","host":"s3://npm-registry-packages-npm-production"}},"1.2.1":{"name":"remend","version":"1.2.1","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.2.1","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"95facafcc603313738d1b6ccf1d08a3a35902595","tarball":"https://registry.npmjs.org/remend/-/remend-1.2.1.tgz","fileCount":5,"integrity":"sha512-4wC12bgXsfKAjF1ewwkNIQz5sqewz/z1xgIgjEMb3r1pEytQ37F0Cm6i+OhbTWEvguJD7lhOUJhK5fSasw9f0w==","signatures":[{"sig":"MEQCIDwrL37ShXOG1XHRHled1+/a9Py1DmZ9YgYhiOq+M06wAiBRcRPx+GmVkd3QjQJF4lzAkgGWao8iqtHOup8PlOnF9g==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/remend@1.2.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":21822},"main":"./dist/index.js","type":"module","_from":"file:remend-1.2.1.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0a5720a0-8248-44a7-b3c7-57ce34ec0043"}},"_resolved":"/tmp/9d29d300d28e488893d3e0df0384393b/remend-1.2.1.tgz","_integrity":"sha512-4wC12bgXsfKAjF1ewwkNIQz5sqewz/z1xgIgjEMb3r1pEytQ37F0Cm6i+OhbTWEvguJD7lhOUJhK5fSasw9f0w==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"11.10.0","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"24.13.1","_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1","vitest":"^4.0.15","@vitest/coverage-v8":"^4.0.15","mdast-util-from-markdown":"^2.0.2"},"_npmOperationalInternal":{"tmp":"tmp/remend_1.2.1_1771519323762_0.05195200233208985","host":"s3://npm-registry-packages-npm-production"}},"1.2.2":{"name":"remend","version":"1.2.2","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.2.2","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"93edf5b53c98beaedcfe584e1f77702d493a8be4","tarball":"https://registry.npmjs.org/remend/-/remend-1.2.2.tgz","fileCount":5,"integrity":"sha512-4ZJgIB9EG9fQE41mOJCRHMmnxDTKHWawQoJWZyUbZuj680wVyogu2ihnj8Edqm7vh2mo/TWHyEZpn2kqeDvS7w==","signatures":[{"sig":"MEUCIFh/aAJmKkbkjs+1M7qdjnPY1nwpy/xVtJ3VgXrXuuT8AiEA9uyrkrlLoER2de+avaplX9qW7a+IpxB7wJAYmyo1rYY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/remend@1.2.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":22405},"main":"./dist/index.js","type":"module","_from":"file:remend-1.2.2.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0a5720a0-8248-44a7-b3c7-57ce34ec0043"}},"_resolved":"/tmp/b64c9ca47dea0f877f93a2867e0fc3ce/remend-1.2.2.tgz","_integrity":"sha512-4ZJgIB9EG9fQE41mOJCRHMmnxDTKHWawQoJWZyUbZuj680wVyogu2ihnj8Edqm7vh2mo/TWHyEZpn2kqeDvS7w==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"11.11.0","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"24.14.0","_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1","vitest":"^4.0.15","@vitest/coverage-v8":"^4.0.15","mdast-util-from-markdown":"^2.0.2"},"_npmOperationalInternal":{"tmp":"tmp/remend_1.2.2_1772737446946_0.44931587730006006","host":"s3://npm-registry-packages-npm-production"}},"1.3.0":{"name":"remend","version":"1.3.0","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","_id":"remend@1.3.0","maintainers":[{"name":"haydenbleasel","email":"hello@haydenbleasel.com"}],"homepage":"https://streamdown.ai/docs/termination","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"81eca27ec38731dc2ff789b44d5e9c8539f36d4e","tarball":"https://registry.npmjs.org/remend/-/remend-1.3.0.tgz","fileCount":5,"integrity":"sha512-iIhggPkhW3hFImKtB10w0dz4EZbs28mV/dmbcYVonWEJ6UGHHpP+bFZnTh6GNWJONg5m+U56JrL+8IxZRdgWjw==","signatures":[{"sig":"MEUCIF0b4W+5nul0Z+7os8XqpZ5BH+5N+Aybmu5ouTuY0hkTAiEAzCqlRjmul1qmN+R9LIhUlcMN2RtF+XkL1YtuyREM7Qo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/remend@1.3.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":23934},"main":"./dist/index.js","type":"module","_from":"file:remend-1.3.0.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0a5720a0-8248-44a7-b3c7-57ce34ec0043"}},"_resolved":"/tmp/e774f40b8c2b9e70a43e3b9a31f1ef9b/remend-1.3.0.tgz","_integrity":"sha512-iIhggPkhW3hFImKtB10w0dz4EZbs28mV/dmbcYVonWEJ6UGHHpP+bFZnTh6GNWJONg5m+U56JrL+8IxZRdgWjw==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"11.11.1","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"_nodeVersion":"24.14.0","_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1","vitest":"^4.0.15","@vitest/coverage-v8":"^4.0.15","mdast-util-from-markdown":"^2.0.2"},"_npmOperationalInternal":{"tmp":"tmp/remend_1.3.0_1773768905040_0.2289673605777025","host":"s3://npm-registry-packages-npm-production"}},"1.3.1":{"_id":"remend@1.3.1","bugs":{"url":"https://github.com/vercel/streamdown/issues"},"dist":{"shasum":"474575f709d39d01f5d3b04333d4fa40d4491133","tarball":"https://registry.npmjs.org/remend/-/remend-1.3.1.tgz","fileCount":5,"integrity":"sha512-N3DiY5qbRPoa5vkxn1oDLMyXOVTeo6Hp+XOj6SIqJAYUgLS0Q587gILPMom/qm86AQ/ZrcOdwEIzCz8V3J0nxQ==","signatures":[{"sig":"MEUCIQCAW3rBrerfZIhvtzUfTKq38hyUyq1jhjJ2j3jKJZ0ZDwIgTdA4MeSJnJIbFAbQ7mBmXHnJ6NKM9mmlAxkvYyFk5Y0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCICKonzzYk04K6zZgN7dSlM03YR7AR0lh9SBW6Lnb/NvIAiBrCreJVvRxwpXpdFGSBUv3Qwte9PKg59c41z2J6FlNIg=="}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/remend@1.3.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":24892},"main":"./dist/index.js","name":"remend","type":"module","_from":"file:remend-1.3.1.tgz","types":"./dist/index.d.ts","author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"license":"Apache-2.0","scripts":{"test":"vitest run","bench":"vitest bench --run > results.txt","build":"tsup","test:ui":"vitest --ui run","bench:ui":"vitest bench --ui --run","test:coverage":"vitest --coverage run"},"version":"1.3.1","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0a5720a0-8248-44a7-b3c7-57ce34ec0043"}},"homepage":"https://streamdown.ai/docs/termination","_resolved":"/tmp/019598af4c4fe06e84c8b2a652e6811a/remend-1.3.1.tgz","_integrity":"sha512-N3DiY5qbRPoa5vkxn1oDLMyXOVTeo6Hp+XOj6SIqJAYUgLS0Q587gILPMom/qm86AQ/ZrcOdwEIzCz8V3J0nxQ==","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"_npmVersion":"12.0.2","description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","directories":{},"maintainers":[{"name":"matt.straka","email":"matt.j.straka@gmail.com"}],"_nodeVersion":"24.19.0","_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1","vitest":"^4.1.10","@vitest/coverage-v8":"^4.1.10","mdast-util-from-markdown":"^2.0.3"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/remend_1.3.1_1787580391791_0.7214552259793527"}}},"time":{"created":"2025-12-03T07:13:55.547Z","modified":"2026-08-24T14:06:32.302Z","0.0.0":"2025-12-03T07:13:55.813Z","0.0.1":"2025-12-03T19:12:00.783Z","1.0.1":"2025-12-03T19:35:46.313Z","1.0.2-canary.0":"2026-01-06T21:42:55.281Z","1.0.2":"2026-01-12T04:43:46.324Z","1.1.0":"2026-01-19T05:09:22.073Z","1.2.0":"2026-02-09T17:31:31.904Z","1.2.1":"2026-02-19T16:42:03.900Z","1.2.2":"2026-03-05T19:04:07.088Z","1.3.0":"2026-03-17T17:35:05.218Z","1.3.1":"2026-08-24T14:06:31.905Z"},"bugs":{"url":"https://github.com/vercel/streamdown/issues"},"author":{"name":"Hayden Bleasel","email":"hayden.bleasel@vercel.com"},"license":"Apache-2.0","homepage":"https://streamdown.ai/docs/termination","repository":{"url":"git+https://github.com/vercel/streamdown.git","type":"git","directory":"packages/remend"},"description":"Self-healing markdown. Intelligently parses and styles incomplete Markdown blocks.","maintainers":[{"name":"matt.straka","email":"matt.j.straka@gmail.com"}],"readme":"# Remend\n\nSelf-healing markdown. Intelligently parses and styles incomplete Markdown blocks.\n\n[![npm version](https://img.shields.io/npm/v/remend)](https://www.npmjs.com/package/remend)\n\n## Overview\n\nRemend is a lightweight utility that handles incomplete Markdown syntax during streaming. When AI models stream Markdown token-by-token, you often get partial formatting markers like unclosed `**bold**` or incomplete `[links](`. Remend automatically completes these unterminated blocks so they render correctly in real-time.\n\nRemend powers the markdown termination logic in [Streamdown](https://streamdown.ai) and can be used standalone in any streaming Markdown application.\n\n## Features\n\n- 🔄 **Streaming-optimized** - Handles incomplete Markdown gracefully\n- 🎨 **Smart completion** - Auto-closes bold, italic, code, links, images, strikethrough, and math blocks\n- ⚡ **Performance-first** - Optimized string operations, no regex allocations\n- 🛡️ **Context-aware** - Respects code blocks, math blocks, and nested formatting\n- 🎯 **Edge case handling** - List markers, word-internal characters, escaped sequences\n- 📦 **Zero dependencies** - Pure TypeScript implementation\n\n## Supported Syntax\n\nRemend intelligently completes the following incomplete Markdown patterns:\n\n- **Bold**: `**text` → `**text**`\n- **Italic**: `*text` or `_text` → `*text*` or `_text_`\n- **Bold + Italic**: `***text` → `***text***`\n- **Inline code**: `` `code `` → `` `code` ``\n- **Strikethrough**: `~~text` → `~~text~~`\n- **Links**: `[text](url` → `[text](streamdown:incomplete-link)`\n- **Images**: `![alt](url` → removed (can't display partial images)\n- **Block math**: `$$formula` → `$$formula$$`\n- **Inline math**: `$formula` → `$formula$` (opt-in, see `inlineKatex`)\n- **Single tilde escape**: `20~25` → `20\\~25` (prevents false strikethrough)\n\n## Installation\n\n```bash\nnpm i remend\n```\n\n## Usage\n\n```typescript\nimport remend from \"remend\";\n\n// During streaming\nconst partialMarkdown = \"This is **bold text\";\nconst completed = remend(partialMarkdown);\n// Result: \"This is **bold text**\"\n\n// With incomplete link\nconst partialLink = \"Check out [this link](https://exampl\";\nconst completed = remend(partialLink);\n// Result: \"Check out [this link](streamdown:incomplete-link)\"\n```\n\n### Configuration\n\nYou can selectively disable specific completions by passing an options object. Options default to `true` unless noted otherwise:\n\n```typescript\nimport remend from \"remend\";\n\n// Disable link and KaTeX completion\nconst completed = remend(partialMarkdown, {\n  links: false,\n  katex: false,\n});\n```\n\nAvailable options:\n\n| Option | Description |\n|--------|-------------|\n| `links` | Complete incomplete links |\n| `images` | Complete incomplete images |\n| `bold` | Complete bold formatting (`**`) |\n| `italic` | Complete italic formatting (`*` and `_`) |\n| `boldItalic` | Complete bold-italic formatting (`***`) |\n| `inlineCode` | Complete inline code formatting (`` ` ``) |\n| `singleTilde` | Escape single `~` between word characters to prevent false strikethrough (e.g. `20~25`) |\n| `strikethrough` | Complete strikethrough formatting (`~~`) |\n| `katex` | Complete block KaTeX math (`$$`) |\n| `inlineKatex` | Complete inline KaTeX math (`$`) — defaults to `false` to avoid ambiguity with currency symbols |\n| `setextHeadings` | Handle incomplete setext headings |\n| `handlers` | Custom handlers to extend remend |\n\n### Custom Handlers\n\nYou can extend remend with custom handlers to complete your own markers during streaming. This is useful for custom syntax like `<<<JOKE>>>` blocks or other domain-specific patterns.\n\n```typescript\nimport remend, { type RemendHandler } from \"remend\";\n\nconst jokeHandler: RemendHandler = {\n  name: \"joke\",\n  handle: (text) => {\n    // Complete <<<JOKE>>> marks that aren't closed\n    const match = text.match(/<<<JOKE>>>([^<]*)$/);\n    if (match && !text.endsWith(\"<<</JOKE>>>\")) {\n      return `${text}<<</JOKE>>>`;\n    }\n    return text;\n  },\n  priority: 80, // Runs after most built-ins (0-70)\n};\n\nconst result = remend(content, { handlers: [jokeHandler] });\n```\n\n#### Handler Interface\n\n```typescript\ninterface RemendHandler {\n  name: string;                    // Unique identifier\n  handle: (text: string) => string; // Transform function\n  priority?: number;               // Lower runs first (default: 100)\n}\n```\n\n#### Built-in Priorities\n\nBuilt-in handlers use priorities 0-75. Custom handlers default to 100 (run after built-ins):\n\n| Handler | Priority |\n|---------|----------|\n| `singleTilde` | 0 |\n| `comparisonOperators` | 5 |\n| `htmlTags` | 10 |\n| `setextHeadings` | 15 |\n| `links` | 20 |\n| `boldItalic` | 30 |\n| `bold` | 35 |\n| `italic` | 40-42 |\n| `inlineCode` | 50 |\n| `strikethrough` | 60 |\n| `katex` | 70 |\n| `inlineKatex` | 75 |\n| Custom (default) | 100 |\n\n#### Exported Utilities\n\nRemend exports utility functions for context detection in custom handlers:\n\n```typescript\nimport {\n  isWithinCodeBlock,\n  isWithinMathBlock,\n  isWithinLinkOrImageUrl,\n  isWordChar,\n} from \"remend\";\n\nconst handler: RemendHandler = {\n  name: \"custom\",\n  handle: (text) => {\n    // Skip if we're inside a code block\n    if (isWithinCodeBlock(text, text.length - 1)) {\n      return text;\n    }\n    // Your logic here\n    return text;\n  },\n};\n```\n\n### Usage with Remark\n\nRemend is a preprocessor that must be run on the raw Markdown string **before** passing it into the unified/remark processing pipeline:\n\n```typescript\nimport remend from \"remend\";\nimport { unified } from \"unified\";\nimport remarkParse from \"remark-parse\";\nimport remarkRehype from \"remark-rehype\";\nimport rehypeStringify from \"rehype-stringify\";\n\nconst streamedMarkdown = \"This is **incomplete bold\";\n\n// Run Remend first to complete incomplete syntax\nconst completedMarkdown = remend(streamedMarkdown);\n\n// Then process with unified\nconst file = await unified()\n  .use(remarkParse)\n  .use(remarkRehype)\n  .use(rehypeStringify)\n  .process(completedMarkdown);\n\nconsole.log(String(file));\n```\n\nThis is important because Remend operates on the raw string level, while remark/unified work with abstract syntax trees (ASTs). Running Remend after parsing would be ineffective.\n\n## How It Works\n\nRemend analyzes the input text and:\n\n1. Detects incomplete formatting markers at the end of the text\n2. Counts opening vs closing markers (considering escaped characters)\n3. Intelligently adds closing markers when needed\n4. Respects context like code blocks, math blocks, and list items\n5. Handles edge cases like nested brackets and word-internal characters\n\nThe parser is designed to be defensive and only completes formatting when it's unambiguous that the block is incomplete.\n\n## Performance\n\nRemend is built for high-performance streaming scenarios:\n\n- Direct string iteration instead of regex splits\n- ASCII fast-path for common characters\n- Minimal memory allocations\n- Early returns for common cases\n\nFor more info, see the [documentation](https://streamdown.ai/docs/termination).\n","readmeFilename":"README.md"}