From 89df2d9475957e6a1ae2a0493d3ab2c8db4b3221 Mon Sep 17 00:00:00 2001 From: Pritesh Nandgaonkar Date: Thu, 15 Feb 2018 06:12:18 -0800 Subject: [PATCH] Google Analytics added Summary: Google analytics added Reviewed By: emilsjolander Differential Revision: D6998583 fbshipit-source-id: 3886964407ec32454da4770b0fe80185e8e18881 --- website/gatsby-config.js | 8 ++++++++ website/package.json | 1 + website/yarn.lock | 6 ++++++ 3 files changed, 15 insertions(+) diff --git a/website/gatsby-config.js b/website/gatsby-config.js index 921592d5..1e8dbbe8 100644 --- a/website/gatsby-config.js +++ b/website/gatsby-config.js @@ -57,5 +57,13 @@ module.exports = { ], }, }, + { + resolve: `gatsby-plugin-google-analytics`, + options: { + trackingId: 'UA-44373548-24', + head: false, + anonymize: true, + }, + }, ], }; diff --git a/website/package.json b/website/package.json index 052cada2..95a15a0f 100644 --- a/website/package.json +++ b/website/package.json @@ -8,6 +8,7 @@ "gatsby": "^1.9.158", "gatsby-link": "^1.6.34", "gatsby-plugin-antd": "^1.0.10", + "gatsby-plugin-google-analytics": "^1.0.19", "gatsby-plugin-less": "^1.1.4", "gatsby-plugin-react-helmet": "^2.0.3", "gatsby-plugin-react-next": "^1.0.8", diff --git a/website/yarn.lock b/website/yarn.lock index 0f722009..1449e9c9 100644 --- a/website/yarn.lock +++ b/website/yarn.lock @@ -3389,6 +3389,12 @@ gatsby-plugin-antd@^1.0.10: antd "^3.1.0" babel-plugin-import "^1.6.3" +gatsby-plugin-google-analytics@^1.0.19: + version "1.0.19" + resolved "https://registry.yarnpkg.com/gatsby-plugin-google-analytics/-/gatsby-plugin-google-analytics-1.0.19.tgz#e9112f01118e0a16eb61f1b39bb0757feba88f2b" + dependencies: + babel-runtime "^6.26.0" + gatsby-plugin-less@^1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/gatsby-plugin-less/-/gatsby-plugin-less-1.1.4.tgz#f226e207b8d17e064865ce3f18b712dea71c4570"