-
-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Labels
enhancementNew feature or requestNew feature or requestpinnedissues that should not be closed by botissues that should not be closed by botv11 target
Description
Today for error handling, since we use exceptions, we need to use error handling helpers (ie isErrorFromAlias and isErrorFromPath) to check errors safely.
To improve error handling, we could also have the hability to disable exceptions and then return an object encapsulating the result.
This way, we can directly return a typed error without requiring to use a helper.
const client = new Zodios(baseurl, myApi, { enableExceptions: false } );
const { data: users, error } = await client.getUsers();
if( error ) {
// typed error
}nd0ut, michael-land, MaximLitvinovZenni and julioz
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestpinnedissues that should not be closed by botissues that should not be closed by botv11 target