在head标签之间,加上如下代码:
<!-- GrowingIO Analytics code version 2.1 --> <!-- Copyright 2015-2018 GrowingIO, Inc. More info available at http://www.growingio.com --> <script type='text/javascript'> !function(e,t,n,g,i){e[i]=e[i]||function(){(e[i].q=e[i].q||[]).push(arguments)},n=t.createElement("script"),tag=t.getElementsByTagName("script")[0],n.async=1,n.src=('https:'==document.location.protocol?'https://':'http://')+g,tag.parentNode.insertBefore(n,tag)}(window,document,"script","assets.giocdn.com/2.1/gio.js","gio"); gio('init','9f42e4f1dee23b1f', {}); //custom page code begin here //custom page code end here gio('send'); </script> <!-- End GrowingIO Analytics code version: 2.1 -->
注意:项目必须部署到生产环境中,并刷新页面进行数据检测;并且gio初始化的id必须填写正确
。
来源:https://www.cnblogs.com/fqh123/p/12394745.html