1.0.1 • Published 6 years ago
carefree v1.0.1
carefree
Call a promise or callback function without care any exception
const carefree = require('carefree');
(async ()=> {
await carefree(async()=>{ throw new Error()});
console.log('Do not care the error above. Just run!');
})();
API
carefree(fn: AsyncFunction | Function | Promise): Promise<Error|null>