2021-02-19 00:32:17 +01:00
|
|
|
=== tests/cases/conformance/es2019/importMeta/importMetaNarrowing.ts ===
|
|
|
|
declare global { interface ImportMeta {foo?: () => void} };
|
|
|
|
>global : Symbol(global, Decl(importMetaNarrowing.ts, 0, 0))
|
|
|
|
>ImportMeta : Symbol(ImportMeta, Decl(lib.es5.d.ts, --, --), Decl(lib.dom.d.ts, --, --), Decl(importMetaNarrowing.ts, 0, 16))
|
|
|
|
>foo : Symbol(ImportMeta.foo, Decl(importMetaNarrowing.ts, 0, 39))
|
|
|
|
|
|
|
|
if (import.meta.foo) {
|
|
|
|
>import.meta.foo : Symbol(ImportMeta.foo, Decl(importMetaNarrowing.ts, 0, 39))
|
2021-08-04 18:41:04 +02:00
|
|
|
>import.meta : Symbol(ImportMeta, Decl(lib.es5.d.ts, --, --), Decl(lib.dom.d.ts, --, --), Decl(importMetaNarrowing.ts, 0, 16))
|
2021-02-19 00:32:17 +01:00
|
|
|
>foo : Symbol(ImportMeta.foo, Decl(importMetaNarrowing.ts, 0, 39))
|
|
|
|
|
|
|
|
import.meta.foo();
|
|
|
|
>import.meta.foo : Symbol(ImportMeta.foo, Decl(importMetaNarrowing.ts, 0, 39))
|
2021-08-04 18:41:04 +02:00
|
|
|
>import.meta : Symbol(ImportMeta, Decl(lib.es5.d.ts, --, --), Decl(lib.dom.d.ts, --, --), Decl(importMetaNarrowing.ts, 0, 16))
|
2021-02-19 00:32:17 +01:00
|
|
|
>foo : Symbol(ImportMeta.foo, Decl(importMetaNarrowing.ts, 0, 39))
|
|
|
|
}
|
|
|
|
|