We will work with an example of what I think is a fairly common scenario: a form that validates and submits some data to create a new resource remotely.
We assume that the Question needs to be created remotely in some backend. Although I don't mention Http specifically, the most common strategy is to do this by making a request to an HTTP API.
In any case, the error type could be something entirely different. It is not relevant to understand the concepts presented in the post.
Great post. I was wondering about the use of Http.Error. Why are you using that when creating a Question, it has nothing to do with Http?
Thank you!
As I say here:
We assume that the
Question
needs to be created remotely in some backend. Although I don't mentionHttp
specifically, the most common strategy is to do this by making a request to an HTTP API.In any case, the error type could be something entirely different. It is not relevant to understand the concepts presented in the post.
Ok, get it. Thanks.