Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/rambda/files/index.d.ts>tryCatch

Faster and smaller alternative to Ramda
Go to Latest
function tryCatch
import { tryCatch } from "https://deno.land/x/rambda@v8.6.0/files/index.d.ts";

Parameters

fn: (input: T) => U
fallback: U

Returns

(input: T) => U

Parameters

fn: (input: T) => U
fallback: (input: T) => U

Returns

(input: T) => U

Parameters

fn: (input: any) => Promise<any>
fallback: T

Returns

(input: any) => Promise<T>

Parameters

fn: (input: any) => Promise<any>
fallback: (input: any) => Promise<any>

Returns

(input: any) => Promise<T>