|
|
hace 2 semanas | |
|---|---|---|
| .. | ||
| test | hace 2 semanas | |
| .eslintrc | hace 2 semanas | |
| .nycrc | hace 2 semanas | |
| CHANGELOG.md | hace 2 semanas | |
| LICENSE | hace 2 semanas | |
| README.md | hace 2 semanas | |
| index.d.ts | hace 2 semanas | |
| index.js | hace 2 semanas | |
| package.json | hace 2 semanas | |
| tsconfig.json | hace 2 semanas | |
Is this a native async function?
var isAsyncFunction = require('is-async-function');
assert(!isAsyncFunction(function () {}));
assert(!isAsyncFunction(null));
assert(!isAsyncFunction(function* () { yield 42; return Infinity; }));
assert(isAsyncFunction(async function () {}));
Simply clone the repo, npm install, and run npm test