https://github.com/simonecorsi/is-async-function
Simple package to check if a function is either an AsyncFunction or not
https://github.com/simonecorsi/is-async-function
async asyncfunction esm github javascript nodejs npm typecheck typescript
Last synced: about 2 months ago
JSON representation
Simple package to check if a function is either an AsyncFunction or not
- Host: GitHub
- URL: https://github.com/simonecorsi/is-async-function
- Owner: simonecorsi
- License: mit
- Created: 2021-10-19T22:11:57.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-10-20T09:03:29.000Z (over 4 years ago)
- Last Synced: 2024-12-20T00:34:07.313Z (over 1 year ago)
- Topics: async, asyncfunction, esm, github, javascript, nodejs, npm, typecheck, typescript
- Language: JavaScript
- Homepage:
- Size: 213 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# is-async-function
This package check if function provided is an AsyncFunction returning true/false.
- [is-async-function](#is-async-function)
- [Installation](#installation)
- [Usage](#usage)
- [Contributing](#contributing)
- [License](#license)
- [Contact](#contact)
## Installation
```sh
npm i --save @scdev/is-async-function
# OR
yarn add @scdev/is-async-function
```
## Usage
```javascript
const isAsyncFunction = require('@scdev/is-async-function');
isAsyncFunction(() => {}) // false
isAsyncFunction(async () => {}) // true
```
## Contributing
Project is pretty simple and straight forward for what is my needs, but if you have any idea you're welcome.
This projects uses [commitizen](https://github.com/commitizen/cz-cli) so be sure to use standard commit format or PR won't be accepted
1. Fork the Project
2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`)
3. Commit your Changes (`git commit -m 'feat(scope): some AmazingFeature'`)
4. Push to the Branch (`git push origin feature/AmazingFeature`)
5. Open a Pull Request
## License
Distributed under the MIT License. See `LICENSE` for more information.
## Contact
Simone Corsi - [@im_simonecorsi](https://twitter.com/im_simonecorsi)