-
Notifications
You must be signed in to change notification settings - Fork 38
Open
Labels
enhancement ✨New feature or requestNew feature or request
Description
By default, for security reasons, Telefunc doesn't pass errors to the client-side.
But this isn't convenient, a good compromise could be:
import { config } form 'telefunc'
config.passErrorToClient = (error) => {
// Pass error if it has a 4xx status code (some validation libraries automatically generate a status code)
return error.statusCode.startsWith('4')
// Completely opt out
return true
}See also: https://telefunc.com/error-handling.
Metadata
Metadata
Assignees
Labels
enhancement ✨New feature or requestNew feature or request