Type guard that checks if the given error is an instance of FraciError.
This is useful in error handling blocks to determine if an error originated from the Fraci library.
The error to check
true if the error is a FraciError, false otherwise
true
false
try { // Some Fraci operation} catch (error) { if (isFraciError(error)) { // Handle Fraci-specific error } else { // Handle other types of errors }} Copy
try { // Some Fraci operation} catch (error) { if (isFraciError(error)) { // Handle Fraci-specific error } else { // Handle other types of errors }}
Type guard that checks if the given error is an instance of FraciError.
This is useful in error handling blocks to determine if an error originated from the Fraci library.