From a84b101f1725c412a8400d07807a44bde764701f Mon Sep 17 00:00:00 2001 From: Josh Kasten Date: Thu, 11 Feb 2021 20:42:31 -0800 Subject: [PATCH 01/26] Setup sub-root sw scope in dev sandbox * Setup the WebSDK in the dev sandbox under a sub directory scope. - This is to confirm the current limitation that this SDK does not work if the page currently viewing isn't under control of the sw. - The following last message is shown in this example - installWorker - Awaiting on navigator.serviceWorker's 'controllerchange' event * Added OneSignalWorker.js under push/onesignal/ as a possible sub-dir someone may want to use onesignal under. * Modified the expresss example's server.js to support the new subfoldered files. --- express_webpack/index.html | 7 +++++++ .../push/onesignal/OneSignalSDKUpdaterWorker.js | 1 + express_webpack/push/onesignal/OneSignalSDKWorker.js | 1 + express_webpack/server.js | 4 ++-- src/helpers/ContextHelper.ts | 4 ++-- 5 files changed, 13 insertions(+), 4 deletions(-) create mode 100644 express_webpack/push/onesignal/OneSignalSDKUpdaterWorker.js create mode 100644 express_webpack/push/onesignal/OneSignalSDKWorker.js diff --git a/express_webpack/index.html b/express_webpack/index.html index 3910c4bfe..a160c559f 100644 --- a/express_webpack/index.html +++ b/express_webpack/index.html @@ -2,6 +2,8 @@