import { fn } from "https://deno.land/x/fun@v2.0.0-alpha.6/mod.ts";
const { tryThunk } = fn;
Wrap a thunk (a Fn that takes no arguments) in a try catch block, using an onThrow function (that should itself never throw) to handle a default case should the original function throw. This is useful for wrapping functions that might throw.