feat(cli): add types for WeakRef/FinalizationRegistry (#8056)

Fixes #8051
This commit is contained in:
Kitson Kelly 2020-10-21 21:57:01 +11:00 committed by GitHub
parent be89bdfed7
commit 0fb39f9176
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 87 additions and 1 deletions

View file

@ -488,6 +488,10 @@ delete Object.prototype.__proto__;
ts.libMap.set("deno.shared_globals", "lib.deno.shared_globals.d.ts");
ts.libMap.set("deno.unstable", "lib.deno.unstable.d.ts");
// TODO(@kitsonk) remove once added to TypeScript
ts.libs.push("esnext.weakref");
ts.libMap.set("esnext.weakref", "lib.esnext.weakref.d.ts");
// this pre-populates the cache at snapshot time of our library files, so they
// are available in the future when needed.
host.getSourceFile(