JSPM

busuanzi.pure.js

1.0.3
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 226
  • Score
    100M100P100Q81945F
  • License MIT

不蒜子访问量统计功能

Package Exports

  • busuanzi.pure.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (busuanzi.pure.js) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

busuanzi.pure.js

 _                                     _                           _
| |__  _   _ ___ _   _  __ _ _ __  ___(_)  _ __  _   _ _ __ ___   (_)___
| '_ \| | | / __| | | |/ _` | '_ \|_  / | | '_ \| | | | '__/ _ \  | / __|
| |_) | |_| \__ \ |_| | (_| | | | |/ /| |_| |_) | |_| | | |  __/_ | \__ \
|_.__/ \__,_|___/\__,_|\__,_|_| |_/___|_(_) .__/ \__,_|_|  \___(_)/ |___/
                                          |_|                   |__/

npm package downloads-total downloads-month star fork GitHub Last Commit issues Author 博客搭建交流群

介绍

    不蒜子访问量统计功能

推荐一款Hexo主题

一个简洁优雅的hexo主题 ➡️ https://github.com/JoeyBling/hexo-theme-yilia-plus

开始使用

yarn add busuanzi.pure.js
# or
npm install busuanzi.pure.js --save

Example

Vue.js

<template>
  <div class="busuanzi">
    <span id="busuanzi_container_site_pv" style="display:none">
      本站总访问量
      <span id="busuanzi_value_site_pv"></span>次
      <span class="post-meta-divider">|</span>
    </span>
    <span id="busuanzi_container_site_uv" style="display:none">
      本站访客数
      <span id="busuanzi_value_site_uv"></span>人
    </span>
  </div>
</template>

<script>
/* 不蒜子访问量统计 */
let script;

export default {
  mounted() {
    script = require("busuanzi.pure.js");
  },
  // 监听,当路由发生变化的时候执行
  watch: {
    $route(to, from) {
      if (to.path != from.path) {
        script.fetch();
      }
      // console.log(to.path);
    }
  }
};
</script>

其它项目支持

关于我

LICENSE

LICENSE