luisfarzati/angulartics — pull request #250 by robertbak (2014-11-24 21:30:33+00:00)
Title: GA multi-account modification

Uses a ```$analyticsProvider.settings.ga``` object for configuration, which after initing multiple analytics accounts like this:

```javascript
ga('create', 'UA-XXXXXX-XX');
ga('create', 'UA-XXXXXX-XY', 'auto', {'name': 'additionalTracker1'});
ga('create', 'UA-XXXXXX-XZ', 'auto', {'name': 'additionalTracker2'});
```

allows to configure the additional providers on startup:

```javascript
config(function ($analyticsProvider) {
$analyticsProvider.settings.ga.additionalAccountNames = ['additionalTracker1', 'additionalTracker2'];
});
```

You can also change the configuration while running the app which, while not the most elegant solution, allows sending only some events to multiple accounts by:

```javascript
$analyticsProvider.settings.ga.additionalAccountNames = ['additionalTracker1'];
$analytics.eventTrack('eventName');
$analyticsProvider.settings.ga.additionalAccountNames = [];
```