@hakimio/ngx-google-analytics
Advanced tools
Changelog
15.0.0
GA4
supportv16
and dropped support for older versionsrxjs
v6
support. Now only rxjs
v7
is supported.NgxGoogleAnalyticsModule.forRoot()
and NgxGoogleAnalyticsRouterModule.forRoot()
are
now replaced by provideGoogleAnalytics()
and provideGoogleAnalyticsRouter()
to set up library's providershostDirectives
in other directivesGoogleAnalyticsService
methods now use options objects to specify additional arguments instead of a long list
of arguments with some of the arguments undefined
.Thanks, @Spejik, for the implementation.
Before:
this.gaService.pageView('/test', 'Test the Title', undefined, {
user_id: 'my-user-id'
});
After:
this.gaService.pageView('/test', {
title: 'Test the Title',
options: {
user_id: 'my-user-id'
}
});