Description
TypeScript Version: 4.2.0-dev.20201129
Search Terms: import.meta.url
Code
export function foo() {
return import.meta.url;
}
Expected behavior: It should work
Actual behavior: Property 'url' does not exist on type 'ImportMeta'.
Playground Link: https://www.typescriptlang.org/play?target=7&ts=4.2.0-dev.20201129#code/KYDwDg9gTgLgBAMwK4DsDGMCWEWIhACgEo4BvAWACg44pgYkpdMBbSWAOhfoEMPGANgG4qAXyA
Related Issues: #41274 didn't add url
in ImportMeta
, which is supported by HTML.