diff --git a/packages/render-helper/CHANGELOG.md b/packages/render-helper/CHANGELOG.md
index 0cbf04c6c6..e0bb1713b7 100644
--- a/packages/render-helper/CHANGELOG.md
+++ b/packages/render-helper/CHANGELOG.md
@@ -1,5 +1,11 @@
# @ecency/render-helper
+## 2.5.27
+
+### Patch Changes
+
+- render-helper: make the node build loadable by plain Node (#1566)
+
## 2.5.26
### Patch Changes
diff --git a/packages/render-helper/dist/THIRD-PARTY-NOTICES.md b/packages/render-helper/dist/THIRD-PARTY-NOTICES.md
new file mode 100644
index 0000000000..b52f0a7f58
--- /dev/null
+++ b/packages/render-helper/dist/THIRD-PARTY-NOTICES.md
@@ -0,0 +1,85 @@
+# Third-party notices
+
+`@ecency/render-helper` bundles the following packages into its published build output.
+Their licences and copyright notices are reproduced here in full, as those licences require.
+
+This file is generated during the build from the bundler's own metafile, so it lists what was
+actually inlined. Do not edit it by hand.
+
+## autolinker 3.16.2
+
+License: MIT
+
+```
+The MIT License (MIT)
+
+Copyright (c) 2014 Gregory Jacobs (http://greg-jacobs.com)
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+```
+
+## remarkable 2.0.1
+
+License: MIT
+
+```
+The MIT License (MIT)
+
+Copyright (c) 2014-2016, Jon Schlinkert
+Copyright (c) 2014 Jon Schlinkert, Vitaly Puzrin.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+```
+
+## tslib 2.8.1
+
+License: 0BSD
+
+```
+Copyright (c) Microsoft Corporation.
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
+REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
+AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
+INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
+OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+PERFORMANCE OF THIS SOFTWARE.
+```
+
diff --git a/packages/render-helper/dist/node/index.cjs b/packages/render-helper/dist/node/index.cjs
index 450c874fa9..efdd7dea70 100644
--- a/packages/render-helper/dist/node/index.cjs
+++ b/packages/render-helper/dist/node/index.cjs
@@ -5,8 +5,6 @@ var he2 = require('he');
var xss = require('xss');
var querystring = require('querystring');
var lruCache = require('lru-cache');
-var remarkable = require('remarkable');
-var linkify$1 = require('remarkable/linkify');
var htmlparser2 = require('htmlparser2');
var domSerializerModule = require('dom-serializer');
@@ -333,17 +331,17 @@ function isAttrNameChar(c) {
function removeDuplicateAttributes(html) {
const n = html.length;
let out = "";
- let i = 0;
- while (i < n) {
- const lt = html.indexOf("<", i);
+ let i2 = 0;
+ while (i2 < n) {
+ const lt = html.indexOf("<", i2);
if (lt < 0) {
- out += html.slice(i);
+ out += html.slice(i2);
break;
}
- out += html.slice(i, lt);
+ out += html.slice(i2, lt);
if (lt + 1 >= n || !isAsciiLetter(html.charCodeAt(lt + 1))) {
out += "<";
- i = lt + 1;
+ i2 = lt + 1;
continue;
}
let p2 = lt + 1;
@@ -351,7 +349,7 @@ function removeDuplicateAttributes(html) {
const tagName = html.slice(lt + 1, p2);
if (p2 >= n || !isSpaceChar(html.charCodeAt(p2))) {
out += "<";
- i = lt + 1;
+ i2 = lt + 1;
continue;
}
const attrs = [];
@@ -415,13 +413,13 @@ function removeDuplicateAttributes(html) {
}
if (q >= n || html.charCodeAt(q) !== 62) {
out += "<";
- i = lt + 1;
+ i2 = lt + 1;
continue;
}
q++;
const attrsJoined = attrs.length > 0 ? " " + attrs.join(" ") : "";
out += "<" + tagName + attrsJoined + (selfClose ? " /" : "") + ">";
- i = q;
+ i2 = q;
}
return out;
}
@@ -442,14 +440,14 @@ function makeEntryCacheKey(entry) {
function stripHtmlTags(s) {
const n = s.length;
let out = "";
- let i = 0;
- while (i < n) {
- const lt = s.indexOf("<", i);
+ let i2 = 0;
+ while (i2 < n) {
+ const lt = s.indexOf("<", i2);
if (lt < 0) {
- out += s.slice(i);
+ out += s.slice(i2);
break;
}
- out += s.slice(i, lt);
+ out += s.slice(i2, lt);
const gt = s.indexOf(">", lt + 1);
if (gt < 0) {
out += s.slice(lt);
@@ -457,10 +455,10 @@ function stripHtmlTags(s) {
}
if (gt === lt + 1) {
out += s.slice(lt, gt + 1);
- i = gt + 1;
+ i2 = gt + 1;
continue;
}
- i = gt + 1;
+ i2 = gt + 1;
}
return out;
}
@@ -479,38 +477,38 @@ function isHtmlWhitespace(c) {
function moveBlockClosingTagOutOfParagraph(html, blockTags) {
const n = html.length;
let out = "";
- let i = 0;
- while (i < n) {
- const pStart = html.indexOf("