import { GoogleAnalytics } from '@awesome-cordova-plugins/google-analytics/ngx';
constructor(private ga: GoogleAnalytics) { }
...
this.ga.startTrackerWithId('YOUR_TRACKER_ID')
.then(() => {
console.log('Google analytics is ready now');
this.ga.trackView('test');
})
.catch(e => console.log('Error starting GoogleAnalytics', e));