jasontaylordev / RapidBlazor

Clean Architecture Solution Template for Blazor WebAssembly .NET 7
MIT License
291 stars 53 forks source link

Blazored.FluentValidation #9

Open vdht opened 1 year ago

vdht commented 1 year ago

First of all thank you for this template, Jason! This saves me a lot!

I was wondering why client validation is not involved in this template? In the TodoLists.razor component there is an EditForm to create a new ToDo list based on the TodoListDto class. I noticed that the client validation is not triggered / not used because the TodoListDto has no validator configured. I do see but that doesn't do anything because there is no DI configuration in program.cs for this. Only the server side validation "CreateTodoListRequestValidator" is triggered. It this on purpose? What is the best practice in combination with clean architecture? Should I add client validation on the ToListDto class or should I use the CreateTodoListRequest class as model for the EditForm?

Thanks! Tim