aboutsummaryrefslogtreecommitdiffhomepage
path: root/public/workbox-v4.3.1/workbox-offline-ga.prod.js
diff options
context:
space:
mode:
authorgithub-actions[bot] <github-actions[bot]@users.noreply.github.com>2022-11-21 22:00:30 +0000
committergithub-actions[bot] <github-actions[bot]@users.noreply.github.com>2022-11-21 22:00:30 +0000
commit6ec00afac5afc892dca5a184b66467d9408f14a5 (patch)
tree6440bf43eafdf75a376b94b9636f3ccac7b3f716 /public/workbox-v4.3.1/workbox-offline-ga.prod.js
parent7fede4ee94880f09f44697104c0696e44fc2f8b6 (diff)
downloadsubmelon.dev-6ec00afac5afc892dca5a184b66467d9408f14a5.tar.gz
submelon.dev-6ec00afac5afc892dca5a184b66467d9408f14a5.tar.bz2
submelon.dev-6ec00afac5afc892dca5a184b66467d9408f14a5.zip
chore: autopublish 2022-11-21T22:00:30Z
Diffstat (limited to 'public/workbox-v4.3.1/workbox-offline-ga.prod.js')
-rw-r--r--public/workbox-v4.3.1/workbox-offline-ga.prod.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/public/workbox-v4.3.1/workbox-offline-ga.prod.js b/public/workbox-v4.3.1/workbox-offline-ga.prod.js
new file mode 100644
index 0000000..ca29dc7
--- /dev/null
+++ b/public/workbox-v4.3.1/workbox-offline-ga.prod.js
@@ -0,0 +1,2 @@
+this.workbox=this.workbox||{},this.workbox.googleAnalytics=function(e,t,o,n,a,c,w){"use strict";try{self["workbox:google-analytics:4.3.1"]&&_()}catch(e){}const r=/^\/(\w+\/)?collect/,s=e=>async({queue:t})=>{let o;for(;o=await t.shiftRequest();){const{request:n,timestamp:a}=o,c=new URL(n.url);try{const w="POST"===n.method?new URLSearchParams(await n.clone().text()):c.searchParams,r=a-(Number(w.get("qt"))||0),s=Date.now()-r;if(w.set("qt",s),e.parameterOverrides)for(const t of Object.keys(e.parameterOverrides)){const o=e.parameterOverrides[t];w.set(t,o)}"function"==typeof e.hitFilter&&e.hitFilter.call(null,w),await fetch(new Request(c.origin+c.pathname,{body:w.toString(),method:"POST",mode:"cors",credentials:"omit",headers:{"Content-Type":"text/plain"}}))}catch(e){throw await t.unshiftRequest(o),e}}},i=e=>{const t=({url:e})=>"www.google-analytics.com"===e.hostname&&r.test(e.pathname),o=new w.NetworkOnly({plugins:[e]});return[new n.Route(t,o,"GET"),new n.Route(t,o,"POST")]},l=e=>{const t=new c.NetworkFirst({cacheName:e});return new n.Route(({url:e})=>"www.google-analytics.com"===e.hostname&&"/analytics.js"===e.pathname,t,"GET")},m=e=>{const t=new c.NetworkFirst({cacheName:e});return new n.Route(({url:e})=>"www.googletagmanager.com"===e.hostname&&"/gtag/js"===e.pathname,t,"GET")},u=e=>{const t=new c.NetworkFirst({cacheName:e});return new n.Route(({url:e})=>"www.googletagmanager.com"===e.hostname&&"/gtm.js"===e.pathname,t,"GET")};return e.initialize=((e={})=>{const n=o.cacheNames.getGoogleAnalyticsName(e.cacheName),c=new t.Plugin("workbox-google-analytics",{maxRetentionTime:2880,onSync:s(e)}),w=[u(n),l(n),m(n),...i(c)],r=new a.Router;for(const e of w)r.registerRoute(e);r.addFetchListener()}),e}({},workbox.backgroundSync,workbox.core._private,workbox.routing,workbox.routing,workbox.strategies,workbox.strategies);
+//# sourceMappingURL=workbox-offline-ga.prod.js.map