diff --git a/.github/workflows/admin-sample.cd.yml b/.github/workflows/admin-sample.cd.yml
index 0e20c83b5a..20c90a0b1e 100644
--- a/.github/workflows/admin-sample.cd.yml
+++ b/.github/workflows/admin-sample.cd.yml
@@ -69,6 +69,56 @@ jobs:
path: ${{env.DOTNET_ROOT}}/server
include-hidden-files: true # Required for wwwroot/.well-known folder
+ deploy_blazor_wasm_standalone:
+ name: build blazor wasm standalone
+ runs-on: ubuntu-24.04
+
+ steps:
+
+ - name: Checkout source code
+ uses: actions/checkout@v4
+
+ - name: Setup .NET
+ uses: actions/setup-dotnet@v4
+ with:
+ global-json-file: src/global.json
+
+ - name: Create project from Boilerplate
+ run: |
+ cd src/Templates/Boilerplate && dotnet build -c Release
+ dotnet pack -c Release -o . -p:ReleaseVersion=0.0.0 -p:PackageVersion=0.0.0
+ dotnet new install Bit.Boilerplate.0.0.0.nupkg
+ cd ../../../ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --appInsights --sentry --serverUrl ${{ env.SERVER_ADDRESS }} --filesStorage AzureBlobStorage --notification --captcha reCaptcha --signalR --framework net9.0
+
+ - name: Update core appsettings.json
+ uses: devops-actions/variable-substitution@v1.2
+ with:
+ files: 'AdminPanel/src/Shared/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Core/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Web/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Web/appsettings.Production.json'
+ env:
+ ServerAddress: ${{ env.SERVER_ADDRESS }}
+ Logging.Sentry.Dsn: ${{ secrets.ADMINPANEL_SENTRY_DSN }}
+ GoogleRecaptchaSiteKey: ${{ secrets.GOOGLE_RECAPTCHA_SITE_KEY }}
+ AdsPushVapid.PublicKey: ${{ secrets.ADMINPANEL_PUBLIC_VAPIDKEY }}
+ ApplicationInsights.ConnectionString: ${{ secrets.APPLICATION_INSIGHTS_CONNECTION_STRING }}
+
+ - uses: actions/setup-node@v4
+ with:
+ node-version: 22
+
+ - name: Install wasm
+ run: cd src && dotnet workload install wasm-tools
+
+ - name: Generate CSS/JS files
+ run: dotnet build AdminPanel/src/Client/AdminPanel.Client.Core/AdminPanel.Client.Core.csproj -t:BeforeBuildTasks -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --no-restore -c Release
+
+ - name: Publish
+ run: dotnet publish AdminPanel/src/Client/AdminPanel.Client.Web/AdminPanel.Client.Web.csproj -c Release -p:PwaEnabled=true -o ${{env.DOTNET_ROOT}}/client -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}"
+
+ - name: Upload to asw
+ run: |
+ npm install -g @azure/static-web-apps-cli
+ swa deploy --deployment-token ${{ secrets.ADMINPANEL_ASW_TOKEN }} --env production --app-location ${{env.DOTNET_ROOT}}/client/wwwroot
+
deploy_api_blazor:
name: deploy api + blazor
needs: build_api_blazor
diff --git a/.github/workflows/todo-sample.cd.yml b/.github/workflows/todo-sample.cd.yml
index 387e890cd5..b668a00726 100644
--- a/.github/workflows/todo-sample.cd.yml
+++ b/.github/workflows/todo-sample.cd.yml
@@ -121,6 +121,53 @@ jobs:
CLOUDFLARE_ZONE: ${{ secrets.BITPLATFORM_DEV_CLOUDFLARE_ZONE }}
CLOUDFLARE_TOKEN: ${{ secrets.CLOUDFLARE_TOKEN }}
+ deploy_blazor_wasm_standalone:
+ name: build blazor wasm standalone
+ runs-on: ubuntu-24.04
+
+ steps:
+
+ - name: Checkout source code
+ uses: actions/checkout@v4
+
+ - name: Setup .NET
+ uses: actions/setup-dotnet@v4
+ with:
+ global-json-file: src/global.json
+
+ - name: Create project from Boilerplate
+ run: |
+ cd src/Templates/Boilerplate && dotnet build -c Release
+ dotnet pack -c Release -o . -p:ReleaseVersion=0.0.0 -p:PackageVersion=0.0.0
+ dotnet new install Bit.Boilerplate.0.0.0.nupkg
+ cd ../../../ && dotnet new bit-bp --name TodoSample --database PostgreSQL --sample Todo --serverUrl ${{ env.SERVER_ADDRESS }} --filesStorage AzureBlobStorage --notification --captcha reCaptcha --framework net9.0
+
+ - name: Update core appsettings.json
+ uses: devops-actions/variable-substitution@v1.2
+ with:
+ files: 'TodoSample/src/Shared/appsettings.json, TodoSample/src/Client/TodoSample.Client.Core/appsettings.json, TodoSample/src/Client/TodoSample.Client.Web/appsettings.json, TodoSample/src/Client/TodoSample.Client.Web/appsettings.Production.json'
+ env:
+ ServerAddress: ${{ env.SERVER_ADDRESS }}
+ GoogleRecaptchaSiteKey: ${{ secrets.GOOGLE_RECAPTCHA_SITE_KEY }}
+
+ - uses: actions/setup-node@v4
+ with:
+ node-version: 22
+
+ - name: Install wasm
+ run: cd src && dotnet workload install wasm-tools
+
+ - name: Generate CSS/JS files
+ run: dotnet build TodoSample/src/Client/TodoSample.Client.Core/TodoSample.Client.Core.csproj -t:BeforeBuildTasks -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --no-restore -c Release
+
+ - name: Publish
+ run: dotnet publish TodoSample/src/Client/TodoSample.Client.Web/TodoSample.Client.Web.csproj -c Release -p:PwaEnabled=true -o ${{env.DOTNET_ROOT}}/client -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" -p:RunAOTCompilation=true -p:MultilingualEnabled=false
+
+ - name: Upload to asw
+ run: |
+ npm install -g @azure/static-web-apps-cli
+ swa deploy --deployment-token ${{ secrets.TODO_ASW_TOKEN }} --env production --app-location ${{env.DOTNET_ROOT}}/client/wwwroot
+
build_blazor_hybrid_windows:
name: build blazor hybrid (windows)
runs-on: windows-2022
diff --git a/README.md b/README.md
index d189ce9e8f..d0ffb560b2 100644
--- a/README.md
+++ b/README.md
@@ -47,7 +47,9 @@ The following apps are our open-source projects powered by the bit platform show
1. [bitplatform.dev](https://bitplatform.dev): .NET 9 Pre-rendered SPA with Blazor WebAssembly
2. [blazorui.bitplatform.dev](https://blazorui.bitplatform.dev): .NET 9 Pre-rendered PWA with Blazor WebAssembly
3. [todo.bitplatform.dev](https://todo.bitplatform.dev): .NET 8 Pre-rendered PWA with Blazor WebAssembly
-5. [adminpanel.bitplatform.dev](https://adminpanel.bitplatform.dev): .NET 9 PWA with Blazor WebAssembly Standalone (Hosted on Cloudflare Pages)
+5. [adminpanel.bitplatform.dev](https://adminpanel.bitplatform.dev): .NET 9 PWA with Blazor WebAssembly
+6. [adminpanel.bitplatform.cc](https://adminpanel.bitplatform.cc): .NET 9 PWA with Blazor WebAssembly Standalone (Free Azure static web app)
+7. [todo.bitplatform.cc](https://todo.bitplatform.cc): AOT Compiled .NET 9 PWA with Blazor WebAssembly Standalone (Free Azure static web app)
[Todo](https://todo.bitplatform.dev) & [Adminpanel](https://adminpanel.bitplatform.dev) web apps will launch their respective Android and iOS applications if you have already installed them, mirroring the behavior of apps like YouTube and Instagram.
diff --git a/src/BlazorUI/Demo/Bit.BlazorUI.Demo.Server/Components/App.razor b/src/BlazorUI/Demo/Bit.BlazorUI.Demo.Server/Components/App.razor
index 8d494028ae..97d974449b 100644
--- a/src/BlazorUI/Demo/Bit.BlazorUI.Demo.Server/Components/App.razor
+++ b/src/BlazorUI/Demo/Bit.BlazorUI.Demo.Server/Components/App.razor
@@ -60,34 +60,31 @@
}
- @if (HttpContext.Request.IsCrawlerClient() is false)
+
+ @if (AppRenderMode.PwaEnabled)
+ {
+
+
+
+ }
+ else
{
-
- @if (AppRenderMode.PwaEnabled)
- {
-
-
-
- }
- else
- {
-
- }
-
-
-
-
+ }
+ });
+
}
+
+
+
+