Options
All
  • Public
  • Public/Protected
  • All
Menu

The type of import.meta.

If you need to declare that a given property exists on import.meta, this type may be augmented via interface merging.

Hierarchy

  • ImportMeta

Index

Properties

Methods

Properties

url

url: string

Methods

Optional resolve

  • resolve(specified: string, parent?: string | URL): Promise<string>
  • experimental

    This feature is only available with the --experimental-import-meta-resolve command flag enabled.

    Provides a module-relative resolution function scoped to each module, returning the URL string.

    Parameters

    • specified: string

      The module specifier to resolve relative to parent.

    • Optional parent: string | URL

      The absolute parent module URL to resolve from. If none is specified, the value of import.meta.url is used as the default.

    Returns Promise<string>