Comparing version 1.13.0 to 1.14.0
@@ -540,2 +540,5 @@ function _typeof(obj) { | ||
}; | ||
var setRouter = function setRouter(_Router) { | ||
return Router = _Router; | ||
}; | ||
function install(_Vue) { | ||
@@ -559,3 +562,4 @@ var _options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; | ||
var bootstrap = _bootstrap; | ||
var setOptions$1 = setOptions; // export api for usages outside Vuejs context | ||
var setOptions$1 = setOptions; | ||
var setRouter$1 = setRouter; // export api for usages outside Vuejs context | ||
@@ -578,2 +582,2 @@ var query$1 = api.query; | ||
export default install; | ||
export { bootstrap, config$1 as config, customMap$1 as customMap, event$1 as event, exception$1 as exception, install, linker$1 as linker, optIn$1 as optIn, optOut$1 as optOut, pageview$1 as pageview, purchase$1 as purchase, query$1 as query, refund$1 as refund, screenview$1 as screenview, set$1 as set, setOptions$1 as setOptions, time$1 as time }; | ||
export { bootstrap, config$1 as config, customMap$1 as customMap, event$1 as event, exception$1 as exception, install, linker$1 as linker, optIn$1 as optIn, optOut$1 as optOut, pageview$1 as pageview, purchase$1 as purchase, query$1 as query, refund$1 as refund, screenview$1 as screenview, set$1 as set, setOptions$1 as setOptions, setRouter$1 as setRouter, time$1 as time }; |
@@ -544,2 +544,5 @@ 'use strict'; | ||
}; | ||
var setRouter = function setRouter(_Router) { | ||
return Router = _Router; | ||
}; | ||
function install(_Vue) { | ||
@@ -563,3 +566,4 @@ var _options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; | ||
var bootstrap = _bootstrap; | ||
var setOptions$1 = setOptions; // export api for usages outside Vuejs context | ||
var setOptions$1 = setOptions; | ||
var setRouter$1 = setRouter; // export api for usages outside Vuejs context | ||
@@ -598,2 +602,3 @@ var query$1 = api.query; | ||
exports.setOptions = setOptions$1; | ||
exports.setRouter = setRouter$1; | ||
exports.time = time$1; |
@@ -546,2 +546,5 @@ (function (global, factory) { | ||
}; | ||
var setRouter = function setRouter(_Router) { | ||
return Router = _Router; | ||
}; | ||
function install(_Vue) { | ||
@@ -565,3 +568,4 @@ var _options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; | ||
var bootstrap = _bootstrap; | ||
var setOptions$1 = setOptions; // export api for usages outside Vuejs context | ||
var setOptions$1 = setOptions; | ||
var setRouter$1 = setRouter; // export api for usages outside Vuejs context | ||
@@ -600,2 +604,3 @@ var query$1 = api.query; | ||
exports.setOptions = setOptions$1; | ||
exports.setRouter = setRouter$1; | ||
exports.time = time$1; | ||
@@ -602,0 +607,0 @@ |
@@ -1,2 +0,2 @@ | ||
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n((e=e||self).VueGtag={})}(this,(function(e){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function t(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function r(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function o(e){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?r(Object(o),!0).forEach((function(n){t(e,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):r(Object(o)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(o,n))}))}return e}var a=function(){};function i(e){console.warn("[vue-gtag] "+e)}function c(e){return"function"==typeof e}function u(e){return e&&"object"===n(e)&&!Array.isArray(e)}function p(){var e,n=T(),t=n.globalObjectName;"undefined"!=typeof document&&"undefined"!=typeof window&&(e=window)[t].apply(e,arguments)}var f,l,d=function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];var r=T(),o=r.config,a=r.includes;p.apply(void 0,["config",o.id].concat(n)),Array.isArray(a)&&a.forEach((function(e){p.apply(void 0,["config",e.id].concat(n))}))},g=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=T(),r=t.defaultGroupName,o=t.includes,a=n;o&&null==a.send_to&&(a.send_to=o.map((function(e){return e.id})).concat(r)),p("event",e,a)},s=function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];var r=n[0],o={};null==(o="string"==typeof r?{page_path:r,page_location:window.location.href}:r).send_page_view&&(o.send_page_view=!0),g("page_view",o)},v=function(){for(var e=T(),n=e.appName,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];var a=r[0],i={};null==(i="string"==typeof a?{screen_name:a}:a).app_name&&(i.app_name=n),null==i.send_page_view&&(i.send_page_view=!0),g("screen_view",i)},m=function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],n=T(),t=n.includes,r=n.config;window["ga-disable-".concat(r.id)]=e,Array.isArray(t)&&t.forEach((function(n){window["ga-disable-".concat(n.id)]=e}))},y=function(){m(!0)},w={query:p,config:d,event:g,pageview:s,screenview:v,customMap:function(e){d({custom_map:e})},time:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];g.apply(void 0,["timing_complete"].concat(n))},exception:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];g.apply(void 0,["exception"].concat(n))},linker:function(e){d("linker",e)},purchase:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];g.apply(void 0,["purchase"].concat(n))},refund:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];g.apply(void 0,["refund"].concat(n))},set:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];p.apply(void 0,["set"].concat(n))},optIn:function(){m(!1)},optOut:y},h=function(){var e=S();e.$gtag=e.prototype.$gtag=w},b=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=T(),r=t.pageTrackerTemplate,o=t.pageTrackerScreenviewEnabled,a=t.pageTrackerUseFullPath,i=t.appName,c=r(e,n);return c||(o?{app_name:i,screen_name:e.name}:{page_title:e.name,page_path:a?e.fullPath:e.path,page_location:window.location.href})},O=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.to,t=void 0===n?{}:n,r=e.from,a=void 0===r?{}:r,c=e.params,u=void 0===c?{}:c,p=T(),f=p.pageTrackerSkipSamePath,l=p.pageTrackerScreenviewEnabled;if(!f||t.path!==a.path){var d=o(o({},b(t,a)),u);!l||d.app_name?!l||d.screen_name?l?v(d):s(d):i("To use the screenview, name your routes"):i("To use the screenview, add the appName to the plugin options")}},_=function(){var e=A();e&&function(e){var n=S(),t=T(),r=t.onBeforeTrack,o=t.onAfterTrack,a=t.config;e.onReady((function(){n.nextTick().then((function(){w.config(a.params),O({to:e.currentRoute})})),e.afterEach((function(e,t){n.nextTick().then((function(){r(e,t),O({to:e,from:t}),o(e,t)}))}))}))}(e)};function k(){if("undefined"!=typeof document&&"undefined"!=typeof window){var e=T(),n=e.customResourceURL,t=e.customPreconnectOrigin,r=e.enabled,o=e.globalObjectName,a=e.globalDataLayerName,i=e.config,u=e.pageTrackerEnabled,p=e.onReady,f=e.onError,l=e.deferScriptLoad,d=e.disableScriptLoad,g=A(),s=Boolean(u&&g);if(r||y(),null==window[o]&&(window[a]=window[a]||[],window[o]=function(){window[a].push(arguments)}),window[o]("js",new Date),s?_():w.config(i.params),!d)return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new Promise((function(t,r){var o=document.head||document.getElementsByTagName("head")[0],a=document.createElement("script");if(a.async=!0,a.src=e,a.charset="utf-8",a.defer=n.defer,n.preconnectOrigin){var i=document.createElement("link");i.href=n.preconnectOrigin,i.rel="preconnect",o.appendChild(i)}o.appendChild(a),a.onload=t,a.onerror=r}))}("".concat(n,"?id=").concat(i.id,"&l=").concat(a),{preconnectOrigin:t,defer:l}).then((function(){var e=window[o];return c(p)&&p(e),e})).catch((function(e){return c(f)&&f(e),e}))}}var j={customResourceURL:"https://www.googletagmanager.com/gtag/js",customPreconnectOrigin:"https://www.googletagmanager.com",pageTrackerTemplate:a,onBeforeTrack:a,onAfterTrack:a,onReady:a,onError:a,enabled:!0,disableScriptLoad:!1,deferScriptLoad:!1,bootstrap:!0,globalObjectName:"gtag",globalDataLayerName:"dataLayer",pageTrackerUseFullPath:!1,pageTrackerEnabled:!0,pageTrackerScreenviewEnabled:!1,pageTrackerSkipSamePath:!0,defaultGroupName:"default",includes:null,appName:null,config:{id:null,params:{send_page_view:!1}}},T=function(){return j},P=function(e){return function e(n){for(var r=arguments.length,o=new Array(r>1?r-1:0),a=1;a<r;a++)o[a-1]=arguments[a];if(!o.length)return n;var i=o.shift();if(u(n)&&u(i)){for(var c in i)u(i[c])?(n[c]||Object.assign(n,t({},c,{})),e(n[c],i[c])):Object.assign(n,t({},c,i[c]));return e.apply(void 0,[n].concat(o))}}(j,e)},S=function(){return f},A=function(){return l};function E(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=arguments.length>2?arguments[2]:void 0;f=e,l=t,P(n),h(),j.bootstrap&&k()}var N=k,x=P,L=w.query,R=w.config,D=w.event,B=w.pageview,M=w.screenview,U=w.customMap,q=w.time,G=w.exception,I=w.linker,C=w.purchase,F=w.set,$=w.optIn,V=w.optOut,z=w.refund;e.bootstrap=N,e.config=R,e.customMap=U,e.default=E,e.event=D,e.exception=G,e.install=E,e.linker=I,e.optIn=$,e.optOut=V,e.pageview=B,e.purchase=C,e.query=L,e.refund=z,e.screenview=M,e.set=F,e.setOptions=x,e.time=q,Object.defineProperty(e,"__esModule",{value:!0})})); | ||
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n((e=e||self).VueGtag={})}(this,(function(e){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function t(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function r(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function o(e){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?r(Object(o),!0).forEach((function(n){t(e,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):r(Object(o)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(o,n))}))}return e}var a=function(){};function i(e){console.warn("[vue-gtag] "+e)}function c(e){return"function"==typeof e}function u(e){return e&&"object"===n(e)&&!Array.isArray(e)}function p(){var e,n=T(),t=n.globalObjectName;"undefined"!=typeof document&&"undefined"!=typeof window&&(e=window)[t].apply(e,arguments)}var f,l,d=function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];var r=T(),o=r.config,a=r.includes;p.apply(void 0,["config",o.id].concat(n)),Array.isArray(a)&&a.forEach((function(e){p.apply(void 0,["config",e.id].concat(n))}))},s=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=T(),r=t.defaultGroupName,o=t.includes,a=n;o&&null==a.send_to&&(a.send_to=o.map((function(e){return e.id})).concat(r)),p("event",e,a)},g=function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];var r=n[0],o={};null==(o="string"==typeof r?{page_path:r,page_location:window.location.href}:r).send_page_view&&(o.send_page_view=!0),s("page_view",o)},v=function(){for(var e=T(),n=e.appName,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];var a=r[0],i={};null==(i="string"==typeof a?{screen_name:a}:a).app_name&&(i.app_name=n),null==i.send_page_view&&(i.send_page_view=!0),s("screen_view",i)},m=function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],n=T(),t=n.includes,r=n.config;window["ga-disable-".concat(r.id)]=e,Array.isArray(t)&&t.forEach((function(n){window["ga-disable-".concat(n.id)]=e}))},y=function(){m(!0)},w={query:p,config:d,event:s,pageview:g,screenview:v,customMap:function(e){d({custom_map:e})},time:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];s.apply(void 0,["timing_complete"].concat(n))},exception:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];s.apply(void 0,["exception"].concat(n))},linker:function(e){d("linker",e)},purchase:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];s.apply(void 0,["purchase"].concat(n))},refund:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];s.apply(void 0,["refund"].concat(n))},set:function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];p.apply(void 0,["set"].concat(n))},optIn:function(){m(!1)},optOut:y},h=function(){var e=S();e.$gtag=e.prototype.$gtag=w},b=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=T(),r=t.pageTrackerTemplate,o=t.pageTrackerScreenviewEnabled,a=t.pageTrackerUseFullPath,i=t.appName,c=r(e,n);return c||(o?{app_name:i,screen_name:e.name}:{page_title:e.name,page_path:a?e.fullPath:e.path,page_location:window.location.href})},O=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.to,t=void 0===n?{}:n,r=e.from,a=void 0===r?{}:r,c=e.params,u=void 0===c?{}:c,p=T(),f=p.pageTrackerSkipSamePath,l=p.pageTrackerScreenviewEnabled;if(!f||t.path!==a.path){var d=o(o({},b(t,a)),u);!l||d.app_name?!l||d.screen_name?l?v(d):g(d):i("To use the screenview, name your routes"):i("To use the screenview, add the appName to the plugin options")}},_=function(){var e=A();e&&function(e){var n=S(),t=T(),r=t.onBeforeTrack,o=t.onAfterTrack,a=t.config;e.onReady((function(){n.nextTick().then((function(){w.config(a.params),O({to:e.currentRoute})})),e.afterEach((function(e,t){n.nextTick().then((function(){r(e,t),O({to:e,from:t}),o(e,t)}))}))}))}(e)};function k(){if("undefined"!=typeof document&&"undefined"!=typeof window){var e=T(),n=e.customResourceURL,t=e.customPreconnectOrigin,r=e.enabled,o=e.globalObjectName,a=e.globalDataLayerName,i=e.config,u=e.pageTrackerEnabled,p=e.onReady,f=e.onError,l=e.deferScriptLoad,d=e.disableScriptLoad,s=A(),g=Boolean(u&&s);if(r||y(),null==window[o]&&(window[a]=window[a]||[],window[o]=function(){window[a].push(arguments)}),window[o]("js",new Date),g?_():w.config(i.params),!d)return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new Promise((function(t,r){var o=document.head||document.getElementsByTagName("head")[0],a=document.createElement("script");if(a.async=!0,a.src=e,a.charset="utf-8",a.defer=n.defer,n.preconnectOrigin){var i=document.createElement("link");i.href=n.preconnectOrigin,i.rel="preconnect",o.appendChild(i)}o.appendChild(a),a.onload=t,a.onerror=r}))}("".concat(n,"?id=").concat(i.id,"&l=").concat(a),{preconnectOrigin:t,defer:l}).then((function(){var e=window[o];return c(p)&&p(e),e})).catch((function(e){return c(f)&&f(e),e}))}}var j={customResourceURL:"https://www.googletagmanager.com/gtag/js",customPreconnectOrigin:"https://www.googletagmanager.com",pageTrackerTemplate:a,onBeforeTrack:a,onAfterTrack:a,onReady:a,onError:a,enabled:!0,disableScriptLoad:!1,deferScriptLoad:!1,bootstrap:!0,globalObjectName:"gtag",globalDataLayerName:"dataLayer",pageTrackerUseFullPath:!1,pageTrackerEnabled:!0,pageTrackerScreenviewEnabled:!1,pageTrackerSkipSamePath:!0,defaultGroupName:"default",includes:null,appName:null,config:{id:null,params:{send_page_view:!1}}},T=function(){return j},P=function(e){return function e(n){for(var r=arguments.length,o=new Array(r>1?r-1:0),a=1;a<r;a++)o[a-1]=arguments[a];if(!o.length)return n;var i=o.shift();if(u(n)&&u(i)){for(var c in i)u(i[c])?(n[c]||Object.assign(n,t({},c,{})),e(n[c],i[c])):Object.assign(n,t({},c,i[c]));return e.apply(void 0,[n].concat(o))}}(j,e)},S=function(){return f},A=function(){return l};function E(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=arguments.length>2?arguments[2]:void 0;f=e,l=t,P(n),h(),j.bootstrap&&k()}var N=k,x=P,L=function(e){return l=e},R=w.query,D=w.config,B=w.event,M=w.pageview,U=w.screenview,q=w.customMap,G=w.time,I=w.exception,C=w.linker,F=w.purchase,$=w.set,V=w.optIn,z=w.optOut,H=w.refund;e.bootstrap=N,e.config=D,e.customMap=q,e.default=E,e.event=B,e.exception=I,e.install=E,e.linker=C,e.optIn=V,e.optOut=z,e.pageview=M,e.purchase=F,e.query=R,e.refund=H,e.screenview=U,e.set=$,e.setOptions=x,e.setRouter=L,e.time=G,Object.defineProperty(e,"__esModule",{value:!0})})); | ||
//# sourceMappingURL=vue-gtag.umd.min.js.map |
{ | ||
"name": "vue-gtag", | ||
"description": "Global Site Tag (gtag.js) plugin for Vue", | ||
"version": "1.13.0", | ||
"version": "1.14.0", | ||
"author": { | ||
@@ -6,0 +6,0 @@ "name": "Matteo Gabriele", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
86166
1789