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

Remove GOVUKTracker #2152

Merged
merged 1 commit into from
Apr 30, 2020
Merged
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
1 change: 0 additions & 1 deletion app/assets/javascripts/analytics.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
//= require govuk_publishing_components/lib/cookie-functions
//= require analytics/pii
//= require analytics_toolkit/google-analytics-universal-tracker
//= require analytics_toolkit/govuk-tracker
//= require analytics_toolkit/analytics
//= require analytics_toolkit/print-intent
//= require analytics_toolkit/error-tracking
Expand Down
4 changes: 1 addition & 3 deletions app/assets/javascripts/analytics/init.js.erb
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@ var analyticsInit = function() {
var analytics = new GOVUK.StaticAnalytics({
universalId: universalId,
cookieDomain: cookieDomain,
allowLinker: true,
// This is served by Fastly in production, and returns an empty 200 response
govukTrackerUrl: '<%= asset_path "/static/a" %>'
allowLinker: true
});

// Make interface public for virtual pageviews and events
Expand Down
6 changes: 0 additions & 6 deletions app/assets/javascripts/analytics_toolkit/analytics.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,6 @@
delete config.universalId
this.trackers.push(new GOVUK.GoogleAnalyticsUniversalTracker(universalId, config))
}
if (typeof config.govukTrackerUrl !== 'undefined') {
var govukTrackerUrl = config.govukTrackerUrl
delete config.govukTrackerUrl
this.trackers.push(new GOVUK.GOVUKTracker(govukTrackerUrl))
}
}

var PIISafe = function (value) {
Expand All @@ -38,7 +33,6 @@

Analytics.load = function () {
GOVUK.GoogleAnalyticsUniversalTracker.load()
GOVUK.GOVUKTracker.load()
}

Analytics.prototype.defaultPathForTrackPageview = function (location) {
Expand Down
134 changes: 0 additions & 134 deletions app/assets/javascripts/analytics_toolkit/govuk-tracker.js

This file was deleted.

182 changes: 0 additions & 182 deletions spec/javascripts/analytics_toolkit/govuk-tracker.spec.js

This file was deleted.