Delete src/components/Twikoo.astro

This commit is contained in:
2026-06-16 21:33:16 +08:00
committed by GitHub
parent 5f3b9f653a
commit aed5472af3
-26
View File
@@ -1,26 +0,0 @@
<div id="tcomment"></div>
<script>
document.addEventListener('astro:page-load', () => {
function loadTwikoo() {
const commentsContainer = document.getElementById('tcomment');
if (commentsContainer) {
const script = document.createElement('script');
script.src = 'https://cdn.staticfile.org/twikoo/1.6.32/twikoo.all.min.js';
script.async = true;
script.onload = () => {
const initScript = document.createElement('script');
initScript.innerHTML = `
twikoo.init({
envId: 'http://47.108.235.131:40063/',
el: '#tcomment',
});
`;
document.body.appendChild(initScript);
};
document.body.appendChild(script);
}
}
loadTwikoo();
});
</script>