This commit is contained in:
Gilles Soulier
2026-01-17 15:58:01 +01:00
parent 1f7f7da0c3
commit dc19315e5d
5616 changed files with 1609815 additions and 18 deletions

18
webui/node_modules/sucrase/dist/util/isExportFrom.js generated vendored Normal file
View File

@@ -0,0 +1,18 @@
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _keywords = require('../parser/tokenizer/keywords');
var _types = require('../parser/tokenizer/types');
/**
* Starting at `export {`, look ahead and return `true` if this is an
* `export {...} from` statement and `false` if this is a plain multi-export.
*/
function isExportFrom(tokens) {
let closeBraceIndex = tokens.currentIndex();
while (!tokens.matches1AtIndex(closeBraceIndex, _types.TokenType.braceR)) {
closeBraceIndex++;
}
return (
tokens.matchesContextualAtIndex(closeBraceIndex + 1, _keywords.ContextualKeyword._from) &&
tokens.matches1AtIndex(closeBraceIndex + 2, _types.TokenType.string)
);
} exports.default = isExportFrom;