🚀 Socket Launch Week 🚀 Day 5: Introducing Socket Fix.Learn More
Socket
Sign inDemoInstall
Socket

vuepress-plugin-minimal-analytics

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vuepress-plugin-minimal-analytics

Minimal Google Analytics plugin for VuePress

0.1.4
latest
Source
npm
Version published
Maintainers
1
Created
Source

VuePress Plugin Minimal Google Analytics

Minimal Google Analytics plugin for VuePress 1.x

Build Status npm version Greenkeeper badge MIT License

Why

Because sometimes all you need is just the page views without all the bloated libraries.

What

This plugin is based on the official VuePress plugin @vuepress/plugin-google-analytics - npm.

The difference betweeen this plugin and the official one is that it uses a light version of the tracking code as introduced by 🌱 minimalanalytics.com - source code in this gist.

Install

$ npm install -D vuepress-plugin-minimal-analytics

# or

$ yarn add -D vuepress-plugin-minimal-analytics

Usage

Add vuepress-plugin-minimal-analytics in your site or theme config file.

See official docs on using a plugin

// .vuepress/config.js
// or
// .vuepress/theme/index.js

// replace 'XX-XXXXXXXXX-X' with your tracking id
module.exports = {
  plugins: [
    ['minimal-analytics', {ga: 'XX-XXXXXXXXX-X'}]
  ]
}

Options

See Plugin Option API official docs

ga

  • Type: string
  • Default: undefined

Provide the Google Analytics ID to enable integration.

Reference

License

MIT © webmasterish

Keywords

vue

FAQs

Package last updated on 22 Jan 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts