Segment analytics

Hi guys, i was wondering if any of you have any luck using [Segment.io][1] analytics in your ionic apps. I have tried following there javascript tutorial [here][2] without any luck. I have managed to send analytics data when trying it out in browser but when have tried it on a mobile it fails. It looks like the application does not recognise the analytics commands like this one.

analytics.track('Bookmarked Article', {
    title: 'Snow Fall',
    subtitle: 'The Avalanche at Tunnel Creek',
    author: 'John Branch'
});

if anyone has a idea what could be wrong please share

best regards
[1]: https://segment.com/
[2]: https://segment.com/docs/libraries/analytics.js/quickstart/

I’m facing a similar issue, a subset of the events (only the custom events) end up going to Segment, but they are never forwarded to the destinations anyways. Let me know if you have any updates on your side.