.NET MAUI Preview 6 - What You Need To Know

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
dot net six preview six is here which means donna maui preview six is also here with some brand new features for cross platform ios ipad os android mac os and windows applications all built with c sharp and xaml i'm gonna do a quick overview of what's new and how to install it and get set up on your windows pc and also on your mac so tune in [Music] hey everyone i'm james montemagno and i'm back again with another.net maui preview hands-on preview video in a way i've done a lot of deep dives since the very very first preview all the way up to where we are now preview six and i'll do the next preview and then the release candidates and whenever the ga is releasing tons of content coming out but i've been trying to sort of minimize these down give all of you out there what information you need if you're sort of following along with the.net maui journey and also don and maui blazer journey too to get you up and running no matter where you're looking to develop some big changes happen in done maui preview 6 so let's check it out i like to always start where i start all the time which is david's excellent blog post right here and yes he talked about not only dot net 6 preview 6 releasing but the brand new update for dotnet maui the multi-platform app ui that is releasing and it's all coming in in visual studio 2022 preview 2. so now this is sort of like a future looking what you're seeing is they're all in on visual studio 2022 preview 2 which you can run side by side visual studio 2019 but 2022 is where the official support here is going to land which is very exciting and also it has this brand new.net maui workload along with the other.net workloads we recently had david on the xamarin podcast which will soon be the don mountain podcast uh and talk all about it so this is cool whole bunch of new things here flex layout modals view clipping gestures flex layout and a whole lot more additionally brand new updates to go along with the windows app sdk so let's check this out really quick he walks through some of the brand new workload installation here which is pretty cool some new capabilities like gestures are now built in um this is actually cool you can kind of see here he taps on different things and they highlight each other clipping built in to do circle clipping and then native alerts as well so here when we go and tap on different things it pops up the native sheets because the donet maui toolkit is running native capabilities and native ui under the hood also lots of improvements here on single project but let's go ahead and check this out really quick i'm going to go ahead over and simply just bring up my command prompt here my terminal and now what you can do is you can do net sdk check what this will do is it'll check to see what sdks are installed on your machine and report it back to you not only the sdks but also the runtimes so here for example you can actually do like a.net sdk install and get the latest versions i have the latest.net 6 preview here and then it shows you all of your runtimes which i have a lot obviously but what's cool is you can now do something called net workload list and these are net workloads that go along with net itself so you could imagine be a lot of different net workloads and what the team shipped was it down in maui workload and then also sdk workloads for android ios mac catalyst mac os and tv os too which is very cool and don't forget ios also includes ipad os 2. so if you didn't have maui installed here all you need to do is do net workload install maui and you would be good to go now we've been showing maui check which is a global tool that you can install over using.net install and done it maui is still what you would want to use the maui check done maui check this is really cool because it's going to check not only your sdks but it'll also check that open jdk is installed correct versions of visual studio are installed the android emulators sdks web ui for a web webview 2 for edge found and all of those.net sdks so this is going to give you everything that you need so dot net maui check is definitely the way to go but then what you can do is i want to show you some of the differences here so we're going to do is we're going to make dir and i'm going to do maui 6 cd maui 6 i'm just going to do dot net new maui now i don't need to add anything else on to this when i do.net new maui it's going to create a project inside this folder called maui 6. you can also give it dash n and the name but i like to just be inside the folder where it was created and then i can just do start dot and then it'll open the folder here and i can right click open with visual studio 2022 so you definitely need to use visual studio 2022 in this release you can of course compile via command line like i showed you before you can do all that as well but if you want to open up the project browse around vs and deploy vs2022 you can still do some of the other things with vs code and command line so you're there too all right a few things that i want to show you really quick here is that they've actually optimized this template when you do done it new maui if it says there's a template update update those and and recreate the project but one there's beautiful new icons in vs 2022 preview 2. but also check this out if i zoom in over here you'll see that all of the platforms are now right underneath the platforms folder that really cleans it up just like resources here's your fonts your images that are here and again you'll have all of your platforms all that platform specific code that's going to be able to go in there now i also want to point out a few new things that are going on inside of the project so let's zoom out and the first thing i want to show you is that there's this new thing called use maui so this is going to use the maui workload and of course we're multi-targeting up here so this one project for the single project is going to deploy ios android and mac catalyst and of course ios includes ipad os and then there's a win ui project over here too for windows a team is working i think they want to combine those all together as much as they can but for right now this is the the two projects there so this has all the same information remember.net maui is all about creating beautiful native cross-platform ap uis and apps for all the different projects but one thing that the team actually showed me is that use maui also there's other things like use maui essentials and you can set that to true or false so if you had a non-dotnet maui app or non-xamarin forms app you could actually use use not user maui essentials there you go use maui essentials and that would bring in the net maui essentials which is the evolution of xamarin essentials which gives you access to a hundred some on native apis from cross-platform code now use maui brings that in automatically so you don't actually need to add that but i just want to kind of point that out i think that's really really neat it's all included automatically in there and this is going to include all the same stuff with the maui image for the app icon splash screen images fonts all that good stuff down over on my startup page over here same exact thing we have use maui app config we're configuring fonts i also want to point out that we also have um [Music] some other things inside of here like configure fonts configure services that are inside of here there's also the use maui service provider factory or use microsoft extensions provider factory so if you're doing dependency injection and ioc you can add that in there which is really cool i'll also point out that over in any of the pages you can now just come and say using microsoft.maui.essentials check that out and you can also use native things inside of here too so if i wanted to make do a native pop-up here this is now allowed so i could say a weight display alert and i could say internet and then i could do something like connectivity dot network access and then say and you know okay for example and pop up that and of course we'll do a tostring.2string there we go so you can now access native alerts too so we can increase the count do pop-ups all that good stuff what's nice is that you could also deploy to your local ios device too so if you plugged in an ios device you can plug that right in and of course you can always deploy to your android emulator that's what i could be doing right here and you can pick which one you want to go to whichever one you have open and just hit debug so it's going to give you everything in this project and and the template here hasn't changed too much we have a scroll view a stack layout a grid a hello world and some buttons and some labels here and again this is just a single project with all these different things in here if we zoom into the resources notice that the app icons and the dotnetbot and the fonts are all still 100 cross platform right here too so it's going to compile up my android application and then start it in a debug window inside of my android emulator which i have right over here so here we go it's compiling and it is deploying to my device and let's give it a second here and let it deploy all right so the net splash screen comes up which again is cross platform across all the different platforms that it supports uh here we go and now we have welcome to don maui now i don't think that hot reload is working let's see in this one yet i'm not sure if it is i think it was on windows i think the team is still working on some final integrations there but definitely be on the lookout for that but again here look at that i just hit count i checked internet and i have internet which is so cool and i can check and i can count and i can count up over and over and over again check that out boom really cool so this is pretty much the same as you would have seen before now if you do want to get it running on ios you can deploy to your device or open up the command prompt and debug or launch via the command prompt on mac os for both ios android and mac os catalyst for windows if i set this as my startup there's going to be one other thing you need to install which is the new single project msix packaging tools for visual studio 2022 now the windows app sdk is now bundled i believe inside of visual studio 2022 so you don't there used to be multiple installs that you need to do this is the only one that you need to do to get the win ui project deploying for.net maui so i had some problems installing this from the ide so i actually hit download and then open the vizix file the vsix file and just install it that way so if you're running into issues so if you go into the extensions manage extensions you run into issues browsing and downloading it here just go ahead and and download it manually from the website you'll be good to go so but then you should just be able to deploy it over to your device or to your local windows machine actually if you get a prompt up and telling you that you can't deploy it's because you don't have that msix vizx installed it's that extension there so then yeah i should just kind of boot up on my local machine we get all the diagnostic tools everything like that and there we go now i did talk to the team and they did say that there was some quirkiness going on we actually get kind of like a rounded corners with one ui three there was some quirkiness going on in this latest one but i did notice that i think that hot reload was working i may not still be aware yeah so you want to kind of double check that maybe working for you may not be working for you double check that i did notice there were some drawings regressions in this build but you can still get it working play around with it give it a look now one thing that i like also is that david always kind of puts together these really nice looking applications with all these really cool things and you always want to download this weather21 project it is a really nice project that does a lot of the same things it has all the images icons fonts but it also does a bunch of native integrations so it adds dependency injection it has a bunch of custom fonts it configures life cycle events here which is cool it has a tray service a notification service it has proper models view models full mvvm inside of there and i can pop open this application i like the settings page quite a bit too they kind of show off some of the new features in the weather app last time we added gradients into it which was quite cool but this time around you know the app is obviously very beautiful and when you go into the settings you get you know the image download from the internet all clipped up you can pop around and you can tap with gesture recognizers now on imperial or metric here you can tap on support get different pop-ups that you want here sign out you're getting all these different options that you would get with those native dialogues that have been popping up on top of it so definitely check out the weather 21 sample i will doubt i'll put a link in the show notes below so you'll have access to that now of course you'll want to go through check and read everything in case i missed something as i was going through my hands on preview but definitely give them feedback you can always go to the.net maui repo check what the team is up to how many issues there are pull requests that are active projects that they're working on but you can also come into the wiki and my favorite part is actually this roadmap we talked about this and this has been evolving as we went so in fact a few different things happen here first and foremost there's a lot more than david put in the blog post but he also mentioned desktop menu icons device info native views so you can embed.net maui views into a non-don maui app some new shell styling and modals tabs page for wind ui and new triggers now they're planning dot net 6 preview 7 for august again i'll probably have another one here this will bring in app theme bindings which i didn't make it to preview 4 which i thought it did but it's here it's going to have more borders cross-platform life cycle events native app life cycle events frames native embedding shadows and a bunch more and of course going forward you have different police candidates and then ga sometime in november so this is really really cool you want to definitely check this out and there's documentation so again to create the applications you'll need to go here but i also want to point out that some really nice notes here so if you want to do the blazer don maui blazer you'll want to actually check the asp.net web here there's a bunch of other workloads that you'll want to check to make sure that you're up and running fully but i do want to point out that you can walk through building your first app how you can migrate your applications from xamarin forms and of course what other components you'll need to get up and running and of course how to use maui jack so definitely check out all that good stuff and i really like here there's a bunch of great documentation on customizing and here how to customize mappers last week on my live stream which i'll post very soon in the channel is probably out already when you're watching this actually walk through how you can contribute to don and maui if you're looking to do so anyways i just wanted to give you all a quick run through of how to create new projects what's new in the templates specifically and the project types with done maui essentials being bundled right in which is really really awesome being able to tap into that native capabilities with just a single line of code no matter what you want to do and of course what the team is up to in the future as more previews and release candidates come out now if you like this video give it a thumbs up smash it do all those good things that really helps my channel and helps this video get it out to more people if you want more information and me to go deeper on this or also if you want me to boot up my mac and get all the things working over there i totally can i will say the reason i didn't go ahead and do that for this release is that the team has a dependency to build on xcode 13 i think it is i think that's what they said in the blog looking looking looking up xcode13 beta1 yeah so i didn't have time to set that all up because it takes several hours to install xcode as many of you probably know but if you want me to i'll totally do it but i like to just kind of run through here on my local machine and if you want anything else about done maui related let me know i'm also putting out new videos right here on this channel so jam on that subscribe button and ding that notification bell because i'm putting out new videos all the time and many of my videos now are not only for xamarin forms but also down in maui when the things are the same and you're coding the same way i kind of marked that in the title so definitely be on the lookout for that i want to thank all of you for all the great comments and feedback that you've given me on this channel and all my videos and thanks for watching [Music] you
Info
Channel: James Montemagno
Views: 19,056
Rating: 4.9867988 out of 5
Keywords: .net maui, maui, dotnet maui, xamarin, xamarin.forms, cross-platform, preview 6, .net 6 preview 6, single project, xamarin forms, maui 6, maui preview 6, .net maui preview 6
Id: T1T8cn3_kVw
Channel Id: undefined
Length: 17min 51sec (1071 seconds)
Published: Tue Jul 20 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.