maui-blazor-hybrid

maui-blazor-hybrid is a skill for Claude Code, Codex from dotnet/maui-labs. It costs 88 tokens per session (1,583 once invoked), scanned A, original, MIT.

A guide for building and debugging .NET MAUI apps that display Razor web components or embedded HTML and JavaScript inside a native app.

In plain words
What is it for?
It covers BlazorWebView and HybridWebView setup, dependency injection, web assets, JavaScript interop, message contracts, and trimming or NativeAOT concerns.
Why use it?
It helps developers choose the right web view and handle communication between the app’s .NET code and its web interface safely.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It covers BlazorWebView and HybridWebView setup, dependency injection, web assets, JavaScript interop, message contracts, and trimming or NativeAOT concerns.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/dotnet/maui-labs/maui-blazor-hybrid
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add dotnet/maui-labs --skill maui-blazor-hybrid
Clone the repo
git clone --depth 1 https://github.com/dotnet/maui-labs

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for maui-blazor-hybrid

README.md
[![agentmods](https://agentmods.dev/badge/skills/dotnet/maui-labs/maui-blazor-hybrid/github.svg)](https://agentmods.dev/skills/dotnet/maui-labs/maui-blazor-hybrid)
Your own site
<a href="https://agentmods.dev/skills/dotnet/maui-labs/maui-blazor-hybrid"><img src="https://agentmods.dev/badge/skills/dotnet/maui-labs/maui-blazor-hybrid/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for maui-blazor-hybrid

Your own site · 80×15
<a href="https://agentmods.dev/skills/dotnet/maui-labs/maui-blazor-hybrid"><img src="https://agentmods.dev/badge/skills/dotnet/maui-labs/maui-blazor-hybrid.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 88 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,583 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00088 $0.01583
Opus 5 $0.00044 $0.00792
Sonnet 5 $0.00018 $0.00317
Haiku 4.5 $0.00009 $0.00158

Measured 8d ago against content hash 68b8ae790d5b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

maui-blazor-hybrid scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/dotnet-maui/skills/maui-blazor-hybrid/SKILL.md · 171 lines

How it starts

The opening of the file, as written. The whole thing — 171 lines — stays where its author put it; the contents beside it link to each section on GitHub.

MAUI Blazor Hybrid

Use this skill when a MAUI app hosts Razor components or an embedded web surface inside a native app.

Workflow

  1. Inspect MauiProgram.cs, .razor files, wwwroot, and XAML pages that host BlazorWebView or HybridWebView.
  2. Choose the right host:
    • BlazorWebView for Razor components rendered inside MAUI.
    • HybridWebView for HTML/JavaScript content that exchanges messages with .NET without using the Blazor component model.
  3. Register Blazor Hybrid services in MauiProgram.cs.
  4. Keep native services in MAUI DI and consume them from Razor through DI.
  5. Put static web assets under wwwroot or referenced Razor class libraries.
  6. Use JS/.NET interop through documented APIs, not platform WebView internals. For HybridWebView raw messaging, always show SendRawMessage, RawMessageReceived, a JSON DTO contract, and a source-generated JsonSerializerContext/System.Text.Json path when trimming, NativeAOT, Release trimming, or trimming-safe messaging is part of the request. Do not answer with only raw strings or DynamicDependency.
  7. Review trimming and NativeAOT risks for reflection, serialization, and JS interop payloads.
  8. Use DevFlow CDP tools to inspect WebView DOM, console logs, CDP screenshots, and route state when debugging. For Blazor Hybrid stale route/DOM answers, explicitly name maui_cdp_webviews, maui_cdp_source or maui_cdp_evaluate, and at least one evidence tool: maui_cdp_screenshot or maui_logs.

BlazorWebView Pattern

builder.Services.AddMauiBlazorWebView();
<BlazorWebView HostPage="wwwroot/index.html">
    <BlazorWebView.RootComponents>
        <RootComponent Selector="#app" ComponentType="{x:Type local:Routes}" />
    </BlazorWebView.RootComponents>
</BlazorWebView>

Razor components can inject MAUI services registered in the same DI container. Keep platform work behind interfaces so components remain testable. The root component type depends on the template; newer templates often use Routes, while older templates may use Main.

Read the full file on GitHub · 171 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago Changed · -65 tokens per session 68b8ae790d5b
  2. 12d ago First seen · 171 lines · 153 tokens per session scan A f91196ff6370

Subscribe to this mod's changes

maui-blazor-hybrid is a skill published in the GitHub repository dotnet/maui-labs (214 stars, last pushed yesterday), licensed MIT. It adds 88 tokens to every session and 1,583 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

truesheet-usage

Consumer-side guide for integrating @lodev09/react-native-true-sheet into a React Native app. Use this skill whenever the user wants to add, configure, control, or debug a bottom sheet using TrueSheet — including ref-based sheets, named global sheets, web support with TrueSheetProvider/useTrueSheet, React Navigation…

lodev09/react-native-true-sheet · 169 tokens

uniwind

Uniwind — Tailwind CSS v4 styling for React Native. Use when adding, building, or debugging components in a React Native project that uses Uniwind classNames. Covers setup, Metro config, global.css, theming, className props, accent- color props, platform/data/state/responsive variants, CSS variables, custom utilities…

uni-stack/uniwind · 130 tokens

react-native-expert

Expert in React Native, cross-platform mobile development, native modules, and performance optimization. Use when the user mentions mobile, JavaScript, TypeScript, cross platform, iOS, or Android, or when the task involves React Native Architecture, Component Types, Hooks Essentials, or Navigation.

personamanagmentlayer/pcl · 62 tokens

migrate-nativewind-to-uniwind

Migrate a React Native project from NativeWind to Uniwind. Use when the user wants to replace NativeWind with Uniwind, upgrade from NativeWind, switch to Uniwind, or mentions NativeWind-to-Uniwind migration. Handles package removal, config migration, Tailwind 4 upgrade, cssInterop removal, theme conversion, and all…

uni-stack/uniwind · 82 tokens

widgetkit

Build Home Screen, Lock Screen, StandBy, and Control Center widgets for iOS with WidgetKit — Widget/WidgetBundle @main, TimelineProvider vs AppIntentTimelineProvider, TimelineEntry + TimelineReloadPolicy, StaticConfiguration vs AppIntentConfiguration (WidgetConfigurationIntent), WidgetFamily layouts…

TalissonVitorino/kmp-ios-skills · 257 tokens

swiftui-uikit-interop

Bridge UIKit and SwiftUI in both directions on iOS 26. Covers UIViewRepresentable / UIViewControllerRepresentable (makeUIView/updateUIView, makeUIViewController/updateUIViewController, Coordinator + makeCoordinator for delegate/target-action, sizeThatFits(:uiView:context:) with ProposedViewSize, dismantleUIView)…

TalissonVitorino/kmp-ios-skills · 259 tokens