Creating the Project
Creating a New Project
From the Rider Welcome Screen, click on
New Solution. This will open a dialog with Project Types on the left and some input fields on the right.
At the bottom on the left hand side under the heading
Other you will see
Avalonia .NET Core MVVM App select it and then type
Avalonia.MusicStore as the
Solution Name. Everything else can be left as default.
A new project will be created with the following structure.
The folders are:
|Assets||Contains any embedded assets that are compiled into the program.
|Models||This is an empty folder intended for code that is domain specific, non-ui code. Interaction with a database or web api, code to talk to a hardware device. Things like that.|
|ViewModels||This is a folder for all the
|Views||This is a folder for all the
Some of the important files are:
|ViewModelBase.cs||This is a base class that all ViewModels should inherit. It implements the way the ViewModels signal changes to the Views to update the UI. (google
|MainWindowViewModel.cs||This is the ViewModel for your
|MainWindow.axaml||This is the
|App.axaml||This is a
Compiling and Running the Project
Press the debug button top right of the IDE to compile and run the project.
This will show a Window that looks like:
A little plain but we now have a running application, and a blank canvas to start from.