Custom analytics.js URL

Due to country restrictions, in specific cases is necessary to add a custom URL to load the analytics.js file.

It is possible to use the customResourceURL prop in the plugin options

  1. Vue.use(VueAnalytics, {
  2. id: 'UA-XXX-X',
  3. customResourceURL: 'http://your-custom-url/analytics.js'
  4. })

By adding the customResourceURL you won’t be able to switch between debug and production file, so you need to do it manually, depending on which file you want to use.