https://github.com/nof1000/isarrow
🤠ES6: checks whether a value is an arrow function
https://github.com/nof1000/isarrow
arrow es6 function javascript nodejs utility
Last synced: 5 months ago
JSON representation
🤠ES6: checks whether a value is an arrow function
- Host: GitHub
- URL: https://github.com/nof1000/isarrow
- Owner: nof1000
- License: mit
- Created: 2017-01-17T15:18:57.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-05-07T14:30:12.000Z (about 9 years ago)
- Last Synced: 2025-10-19T00:20:23.077Z (8 months ago)
- Topics: arrow, es6, function, javascript, nodejs, utility
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/isarrow
- Size: 10.7 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
isclass
 • 
isarrow
 • 
isasync
## What it's for?
This is Node.js library that checks whether a value is an arrow function
## Install
npm:
```
$ npm install isarrow --save
```
yarn:
```
$ yarn add isarrow
```
## Example
```js
const isArrow = require('isarrow');
console.log(isArrow("hello world")); // > false
console.log(isArrow(function() {})); // > false
console.log(isArrow(async function() {})); // > false
console.log(isArrow(class {})); // > false
console.log(isArrow(() => {})); // > true
console.log(isArrow(async () => {})); // > true
console.log(isArrow(123)); // > false
console.log(isArrow({})); // > false
console.log(isArrow([])); // > false
```
## LICENSE
[MIT](./LICENSE "The MIT License")