调试和跟踪 Hotjar 数据

标签 debugging data-collection hotjar

最近,我们公司开始使用Hotjar来收集使用数据。
由于我是第一次使用该服务,所以犯了一些错误,这让我寻找一种调试方法。看了官方文档、论坛、stackoverflow,一无所获。

我必须做什么/修改才能在 Hotjar 中启用调试?

最佳答案

您可以在跟踪脚本中启用调试。只需在 h._hjSettings 中添加以下行线:
hjdebug:true

<!-- Hotjar Tracking Code for www.example.com -->
<script>
(function(h,o,t,j,a,r){
    h.hj=h.hj||function(){(h.hj.q=h.hj.q||[]).push(arguments)};
    h._hjSettings={hjid:YOUR_CUSTOMER_ID,hjsv:HOTJAR_VERSION_NUMBER,hjdebug:true};         
    a=o.getElementsByTagName('head')[0];
    r=o.createElement('script');r.async=1;
    r.src=t+h._hjSettings.hjid+j+h._hjSettings.hjsv;
    a.appendChild(r);
})(window,document,'//static.hotjar.com/c/hotjar-','.js?sv=');
</script>

当您以这种方式使用跟踪代码时,您的控制台基本上会显示在此过程中发生的所有事情。对我来说,它特别有用,因为它帮助我确保注册的虚拟页面 View 没有任何错误。

Example console output, potentially sensitive informations hidden

关于调试和跟踪 Hotjar 数据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40528159/

相关文章:

eclipse - 在 Eclipse 3.4.2 中调试 tomcat 项目

linux - Py 2.7 架构 : How to persistent HTTP/S with multiple servers and not gather data to send multiple times?

java - 将多个项目添加到链接列表中

javascript - 如何将 Hotjar 代码插入 Laravel 项目?

javascript - 使用相同的 URL 在 SPA 中集成 HotJar

使用运行时库的 Delphi 64 位调试有错误的堆栈帧处于事件状态

iphone - 在 Instruments 中调试 UIAutomation 脚本

java - 相当于Java中C语言的__FUNCTION__