mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-10 09:43:54 +01:00
Merge pull request #2539 from theit8514/export-from-import
Expand support for Export declarations with source parameters
This commit is contained in:
commit
0bbe060074
@ -151,6 +151,24 @@ function _getScriptUrls(script: Script, scripts: Script[], seen: Script[]): Scri
|
||||
start: node.source.range[0] + 1,
|
||||
end: node.source.range[1] - 1
|
||||
});
|
||||
},
|
||||
ExportNamedDeclaration(node: any) {
|
||||
if (node.source) {
|
||||
importNodes.push({
|
||||
filename: node.source.value,
|
||||
start: node.source.range[0] + 1,
|
||||
end: node.source.range[1] - 1
|
||||
});
|
||||
}
|
||||
},
|
||||
ExportAllDeclaration(node: any) {
|
||||
if (node.source) {
|
||||
importNodes.push({
|
||||
filename: node.source.value,
|
||||
start: node.source.range[0] + 1,
|
||||
end: node.source.range[1] - 1
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
// Sort the nodes from last start index to first. This replaces the last import with a blob first,
|
||||
|
Loading…
Reference in New Issue
Block a user