MrDave1999 / SimpleResults

A simple library to implement the Result pattern for returning from services
https://mrdave1999.github.io/SimpleResults
MIT License
103 stars 2 forks source link

feat: Translate from Result object to an implementation of IResult #44

Closed MrDave1999 closed 9 months ago

MrDave1999 commented 9 months ago

Resolves #43

I have used the name "ToHttpResult" because all implementations of Microsoft.AspNetCore.Http.IResult are in the Microsoft.AspNetCore.Http.HttpResults namespace.

At first I was going to use the name "ToMinimalApiResult" but I realized that IResult can also be used in controller actions, so I don't think it's a suitable name. See https://learn.microsoft.com/en-us/aspnet/core/web-api/action-return-types?view=aspnetcore-8.0#httpresults-type