Files
hackathon-v-escape-4ff8b5a6…/frontend/node_modules/generator-function/legacy.js
marianesaldana 80dbd947e5 Initial commit
2026-05-23 08:59:34 -06:00

19 lines
380 B
JavaScript

'use strict';
/** @type {GeneratorFunctionConstructor | false} */
var cached;
/** @type {import('./index.js')} */
module.exports = function getGeneratorFunction() {
if (typeof cached === 'undefined') {
try {
// eslint-disable-next-line no-new-func
cached = Function('return function* () {}')().constructor;
} catch (e) {
cached = false;
}
}
return cached;
};