|
hai 10 meses | |
---|---|---|
.. | ||
test | hai 10 meses | |
.eslintrc | hai 10 meses | |
.nycrc | hai 10 meses | |
CHANGELOG.md | hai 10 meses | |
LICENSE | hai 10 meses | |
README.md | hai 10 meses | |
index.js | hai 10 meses | |
package.json | hai 10 meses |
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