Files
emacs/lisp/emacs-application-framework/app/mermaid/node_modules/try-catch
2020-12-05 21:29:49 +01:00
..
2020-12-05 21:29:49 +01:00
2020-12-05 21:29:49 +01:00
2020-12-05 21:29:49 +01:00
2020-12-05 21:29:49 +01:00
2020-12-05 21:29:49 +01:00

Try Catch License NPM version Dependency Status Build Status Coverage Status

Functional try-catch wrapper

Install

npm i try-catch

Example

const tryCatch = require('try-catch');
const {parse} = JSON;
const [error, result] = tryCatch(parse, 'hello');

if (error)
    console.error(error.message);

License

MIT