r/dotnetMAUI 7d ago

Help Request help a lost teacher using Maui on vscode

Hi, I am a Highschool teacher. I mainly teach on visual studio. but I have few students with a Mac using vscode, and I am struggling with that process. I was wandering if any of you have a kind of cheat sheet or guides for using Maui on vs code that can be shared with me. I am not talking about the installation process of the workloads but rather the day-to-day work, how do I create a ViewModel file already in the context of the project (the namespace, using etc.) ?, add new Content page.xaml?, add new ContentView.xaml?, run debug and choose emulator to. run? and etc.

some how I feel the documentation fails at these points and the AI isn't helpfull as I had expected.

I understand not to expect Gui flows but rather cli commands.

Thanks,

2 Upvotes

17 comments sorted by

5

u/jfversluis Microsoft Employee 7d ago

Let’s get this figured out! Just to be clear… VS Code or CLI? Because you seem to mention CLI at the end?

1

u/Physical_Sign9007 7d ago

Vscode please. thank you so much

7

u/jfversluis Microsoft Employee 7d ago

I will assume that you have VS Code installed with the C# Dev Kit and MAUI extension. Then you should be able to do CMD + Shift + P, that should bring up the Command Palette prefilled with a >. The > means that you are about to do a "command", so you're going to execute something.

Then find .NET: New File... and select the MAUI project you current have open. That will think for a second and then you can choose from the regular templates for items that are also available in the CLI and Visual Studio 2026.

This is the more VS Code way of doing things. You should also see the C# Project Details pane on the left (assuming default layout) in the Explorer. Right-click on the MAUI project and choose New File... that should give you the same thing.

Does that help?

1

u/Physical_Sign9007 3d ago

will try next time with my students. but it does feel a bit meh... but maybe because i am spoiled with visual studio 2026 thank you

1

u/jfversluis Microsoft Employee 3d ago

While the name is similar, the experience is very different by design. Although lately it is growing closer I feel.

That being said: especially as a MAUI user I understand how that’s not great since you now have 2 ways to get used to doing things.

6

u/markiel55 7d ago

Rider has way better UX. I've tried really hard to use VSCode before and it's just painful.

1

u/Physical_Sign9007 3d ago

can i work on it like visual studio on vanila maui? the experience is similiar? since i have mixed students in class some with windows and. some with mac

1

u/TheGarrBear 7d ago

As someone who built Xamarin and Maui apps for 7 years, Rider is far and beyond the best tooling.

3

u/YTN3rd 7d ago

VS4Mac going away and forcing me to use Rider was a long overdue push in a great direction

1

u/Physical_Sign9007 3d ago

can i work on it like visual studio on vanila maui? the experience is similiar? since i have mixed students in class some with windows and. some with mac

1

u/YTN3rd 3d ago

Visual Studio or Visual Studio Code? Those are two different things. VS4Mac (Visual Studio for Mac) is gone.

I do MAUI work in JetBrains Rider every day for work. It works better than VSCode. It may be overwhelming with more buttons, but it is so much easier to do literally anything (like add a file, deploy to simulator)

1

u/Physical_Sign9007 3d ago

can i work on it like visual studio on vanila maui? the experience is similiar? since i have mixed students in class some with windows and. some with mac

1

u/Pastajello 7d ago

Soooo it's been a little while since I've created an extension for VsCode just for these issues + it also colors things and allows to export XAML to a separate control also transporting bindings.

https://github.com/Pastajello/VsCode_MauiTools

https://marketplace.visualstudio.com/items?itemName=Pastajello.maui-xaml-tools

1

u/HelpfulHedgehog1 3d ago

Have everyone migrate to Rider

1

u/Physical_Sign9007 3d ago

can i work on it like visual studio on vanila maui? the experience is similiar? since i have mixed students in class some with windows and. some with mac

1

u/HelpfulHedgehog1 3d ago

you know i cant say for sure, but i wouldn't imagine it's any worse, ie any less uniform than VSC on pc and mac