Skip to content

Commit

Permalink
Fix TS
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolo-ribaudo committed Oct 9, 2024
1 parent 09fbcbe commit 713c2eb
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@ export default declare(api => {
);
}

function maybeMemoize(node: t.Expression | t.Super, scope: Scope) {
function maybeMemoize<T extends t.Expression | t.Super>(
node: T,
scope: Scope,
) {
if (scope.isPure(node) || t.isSuper(node)) {
return { assign: node, ref: t.cloneNode(node) };
}
Expand Down

0 comments on commit 713c2eb

Please sign in to comment.