google analytics cross domain linker breaks angularjs hashtag in path

I have an angularjs project with hash prefix, something like the following:

http://www.test.com/#/home

I am trying to implement google analytics (analytics.js) cross domain tracking. I added the following tracking code to app.js:

$window.ga('create', prop.googleAnalytics.trackingId, 'auto', {allowLinker: true});
$window.ga('require', 'linker');
$window.ga('linker:autoLink', ['domain1', 'domain2'], false, true);
$window.ga('send', 'pageview', $location.path());

The code works but the linker will always insert the linker tag before the hashtag, resulting in something like the following:

http://www.test.com/?_ga=2.166208958.100445280#/home

This breaks the url and I have tried allowAnchor=false, add _ga to the URL, but none of them works, auto linker will just keep inserting _ga tag in place of the hashtag. I can’t use HTML5 mode for my angularjs project because the site is hosted on a shared host where .htaccess is not allowed. Is there any way to force linker to insert _ga at the end of the url?

Source: New feed
Source Url google analytics cross domain linker breaks angularjs hashtag in path