@pakal/tryify
v0.2.1
Published
Tryify is package from Pakal library
Downloads
31
Maintainers
Readme
@pakal/tryify
Tryify is package from Pakal library
Install
$ yarn add @pakal/tryify
Or
$ npm install --save @pakal/tryify
Use
Module
import {
default as tryify
} from '@pakal/tryify';
Browser
<script src="https://unpkg.com/@pakal/tryify/bundle.umd.min.js"></script>
let {
tryify
} = _;
Examples
tryify(function(){})(); // => true
tryify(() => false)(); // => true
tryify(function(){
throw TypeError
})(); // => false
tryify(Object.prototype.hasOwnProperty).call(null, 'foo'); // => false
License
Copyright © Yisrael Eliev, Licensed under the MIT license.