Embed script v8 edit

We updated our public script. It has some cool new features.

Strict UTM

To track campaigns you use UTM-codes. There are 5 different codes: utm_source, utm_campaign, utm_medium, utm_content, and utm_term. To make it more readable we allow customers to use the aforementioned codes plus ref, source, campaign, medium, content, and term.

But for some customers this is not desirable, so we created a way to opt-out. Add data-strict-utm="true" to the embed script and we only allow the following codes: utm_source, utm_campaign, utm_medium, utm_content, and utm_term.

Auto Events

We support collecting events with our auto events script. It’s now available for custom domains as well.

Sessions ID

We added a session ID to page views. This makes it possible to link events to page views.

Build on top of events

It’s now easier to test and build on top of events for developers. Previously, we would forbid our script on localhost to prevent data being send from the developers’ computer. We now allow it and show a warning in the Developer Console of the browser when this happens. We allow events and page views to be send from localhost.

It’s usually a good idea to set data-hostname="example.com" when working locally, so we know we should add the events to example.com.

Bugs

We fixed a bug where invalid events where saved in apps that used prototypes on JavaScript Objects.

If you are a developer you might want to see what changed in our open-source repository.