New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@simpozio/gatsby-plugin-analytics

Package Overview
Dependencies
Maintainers
2
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@simpozio/gatsby-plugin-analytics

Plugin for handling event tracking with Google Analytics and Facebook Pixel.

  • 0.0.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3
decreased by-62.5%
Maintainers
2
Weekly downloads
 
Created
Source

Gatsby Plugin for Analytics

Gatsby plugin that combined logic of Google Analytics and Facebook Pixel in single plugin.

Installation

npm i @simpozio/gatsby-plugin-analytics

Usage

Install plugin package from npm and add plugin configuration to your gatsby-config.js file

/* gatsby-config.js */
module.exports = {
  plugins: [
    {
      resolve: '@simpozio/gatsby-plugin-analytics',
      options: {
        head: true,
        fbq: {
          pixelId: 'your Facebook pixel id',
          disablePushState: true,
          trackViewContent: false,
          trackPageView: false
        },
        gtag: {
          trackingIds: ['your Google Analytics id', 'your Google Ads id', 'your Marketing Platform id'],
          trackPageView: false,
        }
      }
    }
  ]
}

Options

  • head: boolean - if true include script tags into head, else add them to the body
  • fbq: object - configuration for Facebook Pixel, includes next properties:
    • pixelId: number - your Facebook Pixel ID
    • disablePushState: boolean - enable/disable PageView tracking on History updates
    • trackViewContent: boolean - enable/disable tracking of ViewContent event on every route update
    • trackPageView: boolean - enable/disable default PageView tracking
  • gtag: object - configuration for Google gtag.js, includes next properties:
    • trackingIds: string[] - array of tracking ID's of Google Services fits pattern - ['your Google Analytics id', 'your Google Ads id', 'your Marketing Platform id']
    • trackPageView: boolean - enable/disable default PageView tracking

Development

See simpozio-frontend-common library

Keywords

FAQs

Package last updated on 17 Nov 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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc