|
1 | 1 | # .NET MAUI in .NET 10 RC 1 - Release Notes
|
2 | 2 |
|
3 |
| -The following .NET 10 RC 1 release notes describe new features and changes in |
4 |
| -this release. |
| 3 | +Here's a summary of what's new in .NET MAUI in this release: |
5 | 4 |
|
6 |
| -## What's new features |
| 5 | +- .NET MAUI |
| 6 | + - [Diagnostics](#diagnostics) |
| 7 | + - [HybridWebView events](#hybridwebview-events) |
| 8 | + - [RefreshView IsRefreshEnabled](#refreshview-isrefreshenabled) |
| 9 | + - [Deprecated APIs](#deprecated-apis) |
| 10 | +- [.NET for Android](#net-for-android) |
| 11 | + - [CoreCLR runtime experimental support](#experimental-coreclr) |
| 12 | +- [.NET for iOS, Mac Catalyst, macOS, tvOS](#net-for-ios-mac-catalyst-macos-tvos) |
7 | 13 |
|
8 |
| -TBD |
| 14 | +.NET MAUI updates in .NET 10: |
| 15 | + |
| 16 | +- [What's new in .NET MAUI in .NET 10](https://learn.microsoft.com/dotnet/maui/whats-new/dotnet-10) documentation. |
| 17 | + |
| 18 | +## Diagnostics |
| 19 | + |
| 20 | +We've added comprehensive diagnostics and metrics tracking for .NET MAUI applications, focusing on layout performance monitoring with an extensible architecture for future observability needs. |
| 21 | + |
| 22 | + |
| 23 | + |
| 24 | + |
| 25 | + |
| 26 | +**Core Diagnostics Infrastructure:** |
| 27 | + |
| 28 | +- **ActivitySource**: `"Microsoft.Maui"` - Tracks layout operations with detailed timing |
| 29 | +- **Metrics**: `"Microsoft.Maui"` - Records counters and histograms for performance analysis |
| 30 | +- **Feature Switch**: `System.Diagnostics.Metrics.Meter.IsSupported` - Runtime enable/disable for AOT/trimming |
| 31 | + |
| 32 | +**Layout Performance Tracking:** |
| 33 | + |
| 34 | +- Instruments `IView.Measure()` and `IView.Arrange()` operations |
| 35 | +- Records timing data and operation counts with rich contextual tags |
| 36 | +- Zero-allocation struct-based instrumentation using `using` pattern |
| 37 | + |
| 38 | +| Metric Name | Type | Description | |
| 39 | +|-------------|------|-------------| |
| 40 | +| `maui.layout.measure_count` | Counter | Number of measure operations | |
| 41 | +| `maui.layout.measure_duration` | Histogram | Time spent measuring (ns) | |
| 42 | +| `maui.layout.arrange_count` | Counter | Number of arrange operations | |
| 43 | +| `maui.layout.arrange_duration` | Histogram | Time spent arranging (ns) | |
| 44 | + |
| 45 | +See [pull request #31058](https://github.com/dotnet/maui/pull/31058) for more details. |
| 46 | + |
| 47 | +## HybridWebView events |
| 48 | + |
| 49 | +Adds initialization events to `HybridWebView` following the same pattern as `BlazorWebView`, enabling platform-specific customization before and after initialization. |
| 50 | + |
| 51 | +### New Events |
| 52 | + |
| 53 | +- `WebViewInitializing` - Fired before `WebView` creation, allows configuration of platform-specific initialization parameters |
| 54 | +- `WebViewInitialized` - Fired after `WebView` creation, provides access to the native `WebView` instance and settings |
| 55 | + |
| 56 | +## RefreshView IsRefreshEnabled |
| 57 | + |
| 58 | +Added `IsRefreshEnabled` property to be distinct from `IsEnabled` and make the behavior consistent across platforms. |
| 59 | + |
| 60 | +```xml |
| 61 | +<RefreshView IsRefreshEnabled="false"> |
| 62 | + <!-- Login form remains usable --> |
| 63 | + <StackLayout> |
| 64 | + <Entry Placeholder="Username" /> |
| 65 | + <Entry Placeholder="Password" /> |
| 66 | + <Button Text="Login" /> |
| 67 | + </StackLayout> |
| 68 | +</RefreshView> |
| 69 | +``` |
| 70 | + |
| 71 | +## Deprecated APIs |
| 72 | + |
| 73 | +Compressed layout APIs are now marked obsolete. Avoid unnecessary layout nesting instead. |
| 74 | + |
| 75 | +`Performance` and `IPerformanceProvider` types are marked obsolete. |
| 76 | + |
| 77 | +## .NET for Android |
| 78 | + |
| 79 | +This release includes continued integration with multiple .NET runtimes, and several bug fixes. |
| 80 | + |
| 81 | +### (Experimental) CoreCLR |
| 82 | + |
| 83 | +Enables Android apps to run on the CoreCLR runtime (instead of Mono). To use it, add the following to your project file for Android builds: |
| 84 | + |
| 85 | +```xml |
| 86 | +<!-- Use CoreCLR on Android --> |
| 87 | +<PropertyGroup Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'"> |
| 88 | + <UseMonoRuntime>false</UseMonoRuntime> |
| 89 | +</PropertyGroup> |
| 90 | +``` |
| 91 | + |
| 92 | +Please try this in your applications and report any issues; when filing feedback, state that you are using UseMonoRuntime=false. Expect that application size is currently larger than with Mono and that debugging and some runtime diagnostics are not fully functional yet; these areas are actively being improved. This is an experimental feature and not intended for production use. |
| 93 | + |
| 94 | +A detailed list of Android changes can be found on the [dotnet/android GitHub releases](https://github.com/dotnet/android/releases/). |
| 95 | + |
| 96 | +## .NET for iOS, Mac Catalyst, macOS, tvOS |
| 97 | + |
| 98 | +This release includes continued integration with multiple .NET runtimes, and several bug fixes. |
| 99 | + |
| 100 | +## Contributors |
| 101 | + |
| 102 | +Thank you contributors! ❤️ |
0 commit comments