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