diff --git a/.github/workflows/bit.ci.Bswup.yml b/.github/workflows/bit.ci.Bswup.yml
index 5192c57506..2e74e2aad2 100644
--- a/.github/workflows/bit.ci.Bswup.yml
+++ b/.github/workflows/bit.ci.Bswup.yml
@@ -53,3 +53,11 @@ jobs:
- name: dotnet build
run: dotnet build src/Bswup/Bit.Bswup.slnx
+
+ # Runs against Bit.Bswup/wwwroot/*.js, which the build above produces, so this also covers
+ # the build step itself (e.g. the minifier re-introducing downleveled syntax).
+ - name: JS tests (service worker, page script, progress UI)
+ run: |
+ cd src/Bswup/Tests/bit-bswup-js
+ npm ci || npm install
+ npm test
diff --git a/src/Bswup/Bit.Bswup.Demo/Pages/HomePage.razor b/src/Bswup/Bit.Bswup.Demo/Pages/HomePage.razor
index 4ef62a7a95..bb30021363 100644
--- a/src/Bswup/Bit.Bswup.Demo/Pages/HomePage.razor
+++ b/src/Bswup/Bit.Bswup.Demo/Pages/HomePage.razor
@@ -3,7 +3,7 @@
Home
-
222
+111
Hello, world!
diff --git a/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.js b/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.js
index 234b154b45..713c3d4128 100644
--- a/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.js
+++ b/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.js
@@ -2,13 +2,15 @@
self.assetsExclude = [/\.scp\.css$/, /weather\.json$/];
self.caseInsensitiveUrl = true;
-self.precachedAssetsInclude = [/favicon\.ico$/, /icon-512\.png$/, /bit-bw-64\.png$/];
self.externalAssets = [
{
"url": "not-found/script.file.js"
}
];
+// 'lax' is already the default; it is spelled out here because the demo intentionally
+// references a non-existent asset to exercise the progress / error reporting UI, and under
+// 'strict' that would abort the install. See README.md > errorTolerance.
self.errorTolerance = 'lax';
self.importScripts('_content/Bit.Bswup/bit-bswup.sw.js');
diff --git a/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.published.js b/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.published.js
index 98df52a75d..659e94b115 100644
--- a/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.published.js
+++ b/src/Bswup/Bit.Bswup.Demo/wwwroot/service-worker.published.js
@@ -2,7 +2,6 @@
self.assetsExclude = [/\.scp\.css$/, /weather\.json$/];
self.caseInsensitiveUrl = true;
-self.precachedAssetsInclude = [/favicon\.ico$/, /icon-512\.png$/, /bit-bw-64\.png$/];
//self.externalAssets = [
// {
diff --git a/src/Bswup/Bit.Bswup.slnx b/src/Bswup/Bit.Bswup.slnx
index 2b41b652c7..6bf34c2593 100644
--- a/src/Bswup/Bit.Bswup.slnx
+++ b/src/Bswup/Bit.Bswup.slnx
@@ -7,12 +7,12 @@
-
-
+
+
-
-
+
+
diff --git a/src/Bswup/Bit.Bswup/Bit.Bswup.csproj b/src/Bswup/Bit.Bswup/Bit.Bswup.csproj
index 0335bfd2f5..9969d5d918 100644
--- a/src/Bswup/Bit.Bswup/Bit.Bswup.csproj
+++ b/src/Bswup/Bit.Bswup/Bit.Bswup.csproj
@@ -5,10 +5,15 @@
net10.0;net9.0;net8.0
true
-
- BeforeBuildTasks;
- $(ResolveStaticWebAssetsInputsDependsOn)
-
+
+ es2019
@@ -21,41 +26,126 @@
+
-
-
+
+
-
-
-
+
+
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
-
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
\ No newline at end of file
+
diff --git a/src/Bswup/Bit.Bswup/BswupProgress.razor b/src/Bswup/Bit.Bswup/BswupProgress.razor
index 3d6344e5a2..38441d9f76 100644
--- a/src/Bswup/Bit.Bswup/BswupProgress.razor
+++ b/src/Bswup/Bit.Bswup/BswupProgress.razor
@@ -10,24 +10,60 @@
[Parameter] public string? Handler { get; set; }
}
-
- @if (ChildContent is not null)
+@* Configuration is published as data-* attributes and read by bit-bswup.progress.js when it
+ loads (it self-initializes from these attributes). This deliberately avoids emitting an
+ inline
+
+
+
+
+
+