An open API service indexing awesome lists of open source software.

https://github.com/nadjitan/todowebapp

Simple todo web app using ASP NET MVC 6
https://github.com/nadjitan/todowebapp

asp-net-6-mvc bootstrap5 client-side-rendering crud pomelo-entity-framework-mysql railway-app server-side-rendering

Last synced: 2 months ago
JSON representation

Simple todo web app using ASP NET MVC 6

Awesome Lists containing this project

README

        

# TodoWebApp

Simple todo web app using ASP.Net 6 MVC with a MySQL database.

## Code Editors

### Visual Studio

- Just hit the green play button

### VS Code & others

- Install [.NET 6.0 SDK](https://dotnet.microsoft.com/en-us/download/dotnet/6.0) (6.0.400). This is the only version I know of that works in [Railway.app](https://railway.app/) at the time of creating this project. You can change the SDK version in `./global.json`.

- You can now run this command:

> Profiles are stored in `Properties/launchSettings.json`

```sh
$ dotnet watch run --launch-profile HotReload
```

## Railway Deployment

- Add a property group in the `.csproj` file. This property group will only be applied during production.

```xml

true

```

- Add a MySQL database in your Railway project and connect your github repo
- Once it is connected and your website is built add these vars:\
![Railway vars](./samples/railway_vars.jpg)
> MySQL variables will be automatically generated. See [Program.cs](https://github.com/nadjitan/TodoWebApp/blob/master/Program.cs#L18) to know how it is consumed.
- `PORT`: 3000 _(It is usually this number but you can check it when your website is done building in the **Deployments** > **View Logs**)_