Skip to content

Support release candidate import.meta.* variant for node.js #10177

@kwonoj

Description

@kwonoj

Describe the feature

Node.js have few release candidates for import.meta.* variants at https://nodejs.org/api/esm.html#importmetafilename

  • import.meta.filename
  • import.meta.dirname

Other than existing import.meta.url. SWC probably need to downlevel transpilation as same as it treats import.meta.url for CJS.

Babel plugin or link to the feature description

https://nodejs.org/api/esm.html#importmetafilename

Additional context

There are few dependencies actively utilizing these, i.e arktype. (https://github.com/arktypeio/arktype)

Metadata

Metadata

Assignees

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions