FusionAuth / fusionauth-typescript-client

A TypeScript client for FusionAuth
https://fusionauth.io
Apache License 2.0
66 stars 27 forks source link

Strongly typed `fieldErrors` and `generalErrors` #105

Open kasir-barati opened 5 months ago

kasir-barati commented 5 months ago

Hey fellow devs,

I was reading the doc and source code, then realized that we are not typing these two as it should be. Even though we have a much better type support in other programming languages such as Golang and php: https://github.com/FusionAuth/go-client/blob/main/pkg/fusionauth/Domain.go#L2888C2-L2888C13

So if it is not too much to ask please add a more robust typing.

Best regards Mohammad Jawad.

kasir-barati commented 5 months ago

BTW I also realized in my application that I had to redefine the same class called ClientResponse because this SDK when receives a 400 error response it will throw it as an error but I do not have access to its interface