Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(google-analytics): add gatsby-plugin-google-analytics #474

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,14 @@ module.exports = {
},
'gatsby-plugin-react-helmet',
'gatsby-plugin-glamor',
{
resolve: 'gatsby-plugin-google-analytics',
options: {
trackingId: 'GOOGLE_ANALYTICS_TRACKING_ID',
head: true,
cookieDomain: 'dsmjs.com'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since we will need to move this site from the current domain to the actual dsmjs.com domain once the site is operational, i've been hesitant to do this before we get things migrated. i wouldnt mind having confidence that its ready to go though.

since i havent configured a new site for GA for a while, do you know off the top of your head if transitioning domains is well supported or if it would be better to wait?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will it hurt to have this config there as a placeholder, then use an actual tracking ID/set it up on Google Analytics website once this goes live on dsmjs.com?

}
},
{
resolve: 'gatsby-plugin-google-fonts',
options: {
Expand Down
23 changes: 23 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
"gatsby": "2.15.15",
"gatsby-link": "2.2.13",
"gatsby-plugin-glamor": "2.1.7",
"gatsby-plugin-google-analytics": "2.1.23",
"gatsby-plugin-google-fonts": "1.0.1",
"gatsby-plugin-netlify": "2.1.13",
"gatsby-plugin-react-helmet": "3.1.7",
Expand Down