@oazmi/superbuild - v0.1.0
    Preparing search index...

    Implements

    Index

    Constructors

    Properties

    value: Metafile
    inputs: Map<string, Metafile>
    outputs: Map<string, FormattedMetafileOutputProps>
    outputFileEntities: OutputFileEntityMap = ...
    resolvedResourceRegistry: Map<string, BundledInputFile>

    a copy of the SuperBuildContext.resolvedResourceRegistry, where all keys use lower case characters. this is extremely important, as we've internally standardized to using only lower casing for namespaced resolved paths, in order to evade the filesystem case-insesnsitivity problem when matching strings.

    resolvePath: (path: string) => string

    a function that resolves the given path segment to an absolute path, with respect to cwd or absWorkingDir.

    warnings: PartialMessage[] = []

    holds all warnings that have occurred during method calls.

    Methods

    • find the file entity corresponding to the given absolute output path. you won't receive entities associated with external paths/references.

      Parameters

      • output_path_key: string

      Returns OutputFileEntity | undefined

    • find all file entities that incorporate (i.e. originate from) certain namespaced source files/resources into their bundled form.

      Parameters

      • predicate_fn: (file_sources: { namespace: string; path: string }[]) => boolean

      Returns OutputFileEntity[]

    • write all output file entities (those with entity.write !== false) to the filesystem.

      Parameters

      • allow_overwrite: boolean = false

      Returns Promise<void>

    • normalizes an esbuild metafile to use namespaced paths (${namespace}:${resolved_path}) for resolved paths, and absolute paths for output file paths.

      this function mutates the original metafile object passed to it.

      Parameters

      • esbuild_metafile: Metafile

      Returns Metafile

    • lower the casing of an esbuild metafile's namespaced resolved paths, output file paths, and external paths, based on your config configuration.

      lower casing helps in ensuring that there won't be any casing conflicts when searching for a particular resource.

      this function mutates the original metafile object passed to it.

      Parameters

      • esbuild_metafile: Metafile
      • config: { namespacedPaths: boolean; outputPaths: boolean; externalPaths: boolean }
        • namespacedPaths: boolean

          specify if namespaced resolved paths should be lower cased.

        • outputPaths: boolean

          specify if output file paths should be lower cased.

        • externalPaths: boolean

          specify if external import paths should be lower cased.

      Returns Metafile

    • resolve all relative file paths in a normalized esbuild metafile to absolute file paths.

      this function mutates the original metafile object passed to it.

      Parameters

      • esbuild_metafile: Metafile
      • config: { resolvePath: (path: string) => string }

      Returns Metafile