Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions BenchmarkDotNet.Maui.slnx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<Solution>
<Configurations>
<Platform Name="Any CPU" />
<Platform Name="x64" />
<Platform Name="x86" />
</Configurations>
<Folder Name="/samples/">
<Project Path="samples/BenchmarkDotNet.Samples.Maui/BenchmarkDotNet.Samples.Maui.csproj" />
</Folder>
<Folder Name="/src/">
<Project Path="src/BenchmarkDotNet.Annotations/BenchmarkDotNet.Annotations.csproj" />
<Project Path="src/BenchmarkDotNet/BenchmarkDotNet.csproj" />
</Folder>
</Solution>
125 changes: 0 additions & 125 deletions BenchmarkDotNet.Xamarin.sln

This file was deleted.

1 change: 1 addition & 0 deletions docs/_redirects/_redirects
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,4 @@
/Configs/Loggers.htm /articles/configs/loggers.html
/Configs/Validators.htm /articles/configs/validators.html
/Configs/Jobs.htm /articles/configs/jobs.html
/articles/samples/IntroXamarin.html /articles/samples/IntroMaui.html
44 changes: 44 additions & 0 deletions docs/articles/samples/IntroMaui.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
uid: BenchmarkDotNet.Samples.Maui
---

## Sample: IntroMaui

To use BenchmarkDotNet with [.NET MAUI](https://dotnet.microsoft.com/apps/maui), you will need to build a small UI for running benchmarks and displaying the results.

.NET MAUI allows you to run your benchmarks on Android, iOS, Mac Catalyst, and Windows from a single codebase.

Other notes:

* Use `Release` builds when running actual benchmarks.
* Consider disabling trimming appropriately for your benchmarks.

### Source code

[!code-csharp[MainPage.xaml.cs](../../../samples/BenchmarkDotNet.Samples.Maui/MainPage.xaml.cs)]

### Output

#### Windows

![MAUI Output - Windows](../../images/maui-screenshot-windows.png)

#### Android

![MAUI Output - Android](../../images/maui-screenshot-android.png)

#### iOS

![MAUI Output - iOS](../../images/maui-screenshot-ios.png)

#### Mac Catalyst

![MAUI Output - mac](../../images/maui-screenshot-mac.png)

### Links

* [.NET MAUI Documentation](https://learn.microsoft.com/dotnet/maui/)
* [Trimming in .NET MAUI](https://learn.microsoft.com/dotnet/maui/deployment/trimming)
* The permanent link to this sample: @BenchmarkDotNet.Samples.Maui

---
29 changes: 0 additions & 29 deletions docs/articles/samples/IntroXamarin.md

This file was deleted.

4 changes: 2 additions & 2 deletions docs/articles/samples/toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,5 +132,5 @@
href: IntroWasm.md
- name: IntroUnicode
href: IntroUnicode.md
- name: IntroXamarin
href: IntroXamarin.md
- name: IntroMaui
href: IntroMaui.md
Binary file added docs/images/maui-screenshot-android.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/maui-screenshot-ios.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/maui-screenshot-mac.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/maui-screenshot-windows.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed docs/images/xamarin-screenshot.png
Binary file not shown.

This file was deleted.

33 changes: 0 additions & 33 deletions samples/BenchmarkDotNet.Samples.Android/MainActivity.cs

This file was deleted.

This file was deleted.

Loading