Here is the code that can be applied to make the Betterdocs Instant Answer Plugin feature open automatically on the visited page.
<script>
window.onload = function() {
// Cek apakah elemen chat ada di halaman
var chatButton = document.querySelector('.betterdocs-ia-launcher');
if(chatButton) {
// Jika ada, klik tombol chat untuk membuka chat
chatButton.click();
}
};
</script>
You can add this code into the HTML file, just before the closing tag </body>
.
This is what it looks like when it is configured.