Skip to content

Commit

Permalink
name
Browse files Browse the repository at this point in the history
  • Loading branch information
dummdidumm committed Nov 20, 2024
1 parent 1f75da4 commit a517b8b
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ export function processInstanceScriptContent(
moveNode(node, str, astOffset, script.start, tsAst);
}

const hoistable = exportedNames.hoistableInterfaces.moveHoistableInterfaces(
const hoisted = exportedNames.hoistableInterfaces.moveHoistableInterfaces(
str,
astOffset,
script.start + 1, // +1 because imports are also moved at that position, and we want to move interfaces after imports
Expand All @@ -322,12 +322,12 @@ export function processInstanceScriptContent(
// using interfaces inside the return type of a function is forbidden.
// This is not a problem for intellisense/type inference but it will
// break dts generation (file will not be generated).
if (hoistable) {
if (hoisted) {
transformInterfacesToTypes(
tsAst,
str,
astOffset,
[...hoistable.values()].concat(nodesToMove)
[...hoisted.values()].concat(nodesToMove)
);
} else {
transformInterfacesToTypes(tsAst, str, astOffset, nodesToMove);
Expand Down

0 comments on commit a517b8b

Please sign in to comment.