}</p>`
      );
    }
    console.log('initSwirlChat end');
  }

  console.log('registering initSwirlChat listener');
  if (document.readyState === 'loading') {
    document.addEventListener('DOMContentLoaded', initSwirlChat);
  } else {
    console.log('document already ready â€” calling initSwirlChat');
    initSwirlChat();
  }
</script>
