Merge pull request #2002 from umputun/fix/placeholder-clearing-1990

Clear user placeholder content when comments iframe loads
This commit is contained in:
Umputun
2026-02-10 22:50:51 -06:00
committed by GitHub
+5
View File
@@ -79,6 +79,11 @@ function createInstance(config: typeof window.remark_config) {
}
if (data.inited === true) {
// remove placeholder content added by the user before comments loaded
Array.from(root!.childNodes)
.filter((node) => node !== iframe)
.forEach((node) => node.remove());
postHashToIframe();
postTitleToIframe(document.title);
}