Create an account


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Announcing Experimental Mobile Blazor Bindings

#1
Announcing Experimental Mobile Blazor Bindings

Eilon Lipton

Eilon

Today I’m excited to announce a new experimental project to enable native mobile app development with Blazor: Experimental Mobile Blazor Bindings. These bindings enable developers to build native mobile apps using C# and .NET for iOS and Android using familiar web programming patterns. This means you can use the Blazor programming model and Razor syntax to define UI components and behaviors of an application. The UI components that are included are based on Xamarin.Forms native UI controls, which results in beautiful native mobile apps.

Here is a sample Counter component, which may look familiar to Blazor developers, that increments a value on each button press:

<StackLayout> <Label FontSize="30" Text="@("You pressed " + count + " times")" /> <Button Text="+1" On‌Click="@HandleClick" />
</StackLayout> @code { int count; void HandleClick() { count++; }
}

Notice that the Blazor model is present with code sitting side by side the user interface markup that leverages Razor syntax with mobile specific components. This will feel very natural for any web developer that has ever used Razor syntax in the past. Now with the Experimental Mobile Blazor Bindings you can leverage your existing web skills and knowledge to build native iOS and Android apps powered by .NET.

Here is the code above running in the Android Emulator:

Clicking increment button in Android emulator

Get started with Mobile Blazor Bindings


To get started, all you need is the .NET Core 3.0 or 3.1 SDK, Visual Studio or Visual Studio for Mac, and the ASP.NET and web development and Mobile development with .NET (Xamarin.Forms) workloads installed.

Install the templates by running this command from a command/shell window:

dotnet new -i Microsoft.MobileBlazorBindings.Templates::0.1.173-beta

And then create your first project by running this command:

dotnet new mobileblazorbindings -o MyApp

Open the solution (SLN file) in Visual Studio and mark either the Android or iOS project as the StartUp Project, which should look like this:

VS solution with shared UI, Android, and iOS projects

Now run your first Mobile Blazor Bindings app in a local emulator or on an attached mobile device! Don’t have one set up yet for development? No worries, the Xamarin documentation has all the details for you here:

For documentation and walkthroughs, check out the Mobile Blazor Bindings documentation.

Why Mobile Blazor Bindings now?


Many developers delight in using XAML and Xamarin.Forms to craft beautiful native mobile apps. We have heard from a set of developers that come from a web programming background that having web specific patterns to build mobile applications would be ideal for them. The goal of these bindings is to see if developers would like to have the option of writing markup and doing data binding for native mobile applications using the Blazor-style programming model with Razor syntax and features. Would you love to see this option in the box for future versions of Visual Studio?

Learn more


To learn more about Experimental Mobile Blazor Bindings, please check out these resources:

Give feedback


Please send us your feedback via issues in our GitHub repo and by completing a short survey about your experience and expectations.

We hope you try out this new framework and let us know your thoughts!

Eilon Lipton



https://www.sickgaming.net/blog/2020/01/...-bindings/
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Blazor Server in .NET Core 3.0 scenarios and performance xSicKxBot 0 95 10-23-2019, 05:55 AM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 xSicKxBot 0 90 10-22-2019, 04:14 PM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 Release Candidate 1 xSicKxBot 0 101 10-22-2019, 05:26 AM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 Preview 9 xSicKxBot 0 100 10-21-2019, 09:51 PM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 Preview 8 xSicKxBot 0 96 10-21-2019, 09:03 AM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 Preview 9 xSicKxBot 0 228 09-11-2019, 07:27 AM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 Preview 8 xSicKxBot 0 129 09-10-2019, 04:57 PM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 Preview 7 xSicKxBot 0 137 09-09-2019, 09:20 PM
Last Post: xSicKxBot
  Configuring a Server-side Blazor app with Azure App Configuration xSicKxBot 0 146 09-09-2019, 03:07 PM
Last Post: xSicKxBot
  ASP.NET Core and Blazor updates in .NET Core 3.0 Preview 6 xSicKxBot 0 127 09-08-2019, 11:55 PM
Last Post: xSicKxBot

Forum Jump:

[-]
Welcome
You have to register before you can post on our site.

Username:


Password:





[-]
Statistics
» Members: 12,006
» Latest member: matthew.devasure
» Forum threads: 11,107
» Forum posts: 11,501

Full Statistics

[-]
Online Staff
There are no staff members currently online.

[-]
Discord

[-]
Latest Threads
News - Netflix's Ghost In The Shell Show...
Last Post: xSicKxBot
Today 03:19 PM
» Replies: 0
» Views: 0
[Tut] Python Re Dot
Last Post: xSicKxBot
Today 08:01 AM
» Replies: 0
» Views: 5
[Tut] How to Create Popup Contact Form D...
Last Post: xSicKxBot
Today 08:01 AM
» Replies: 0
» Views: 3
(Indie Deal) ?Crypto Lunar New Year Sale...
Last Post: xSicKxBot
Today 08:00 AM
» Replies: 0
» Views: 67
Ursina Engine
Last Post: xSicKxBot
Today 08:00 AM
» Replies: 0
» Views: 3
Mobile - Star Realms follow-up Epic rele...
Last Post: xSicKxBot
Today 08:00 AM
» Replies: 0
» Views: 3
Fedora - Build your own cloud with Fedor...
Last Post: xSicKxBot
Today 08:00 AM
» Replies: 0
» Views: 2
News - 2K Joins The Rest Of The World In...
Last Post: xSicKxBot
Today 08:00 AM
» Replies: 0
» Views: 2
News - Gorgeous Pokemon Skateboards Are ...
Last Post: xSicKxBot
Today 08:00 AM
» Replies: 0
» Views: 2
[Oracle Blog] 2019 Duke's Choice Award N...
Last Post: xSicKxBot
Today 02:23 AM
» Replies: 0
» Views: 4

[-]
Twitter

[-]
Recent Posts
News - Netflix's Ghost In The Shell Show...
Netflix's Ghost In T...xSicKxBot — 03:19 PM
[Tut] Python Re Dot
Python Re Dot You&#...xSicKxBot — 08:01 AM
[Tut] How to Create Popup Contact Form D...
How to Create Popup ...xSicKxBot — 08:01 AM
(Indie Deal) ?Crypto Lunar New Year Sale...
?Crypto Lunar New Ye...xSicKxBot — 08:00 AM
Ursina Engine
Ursina Engine The U...xSicKxBot — 08:00 AM

[-]
Top Poster
no avatar Congratulations to xSicKxBot, our current top poster for the last day with 18 posts!

Copyright © SickGaming.net 2012-2019