simgadget
    Preparing search index...

    Function prefetchCompanion

    • Resolves the pinned idb_companion, downloading it if it is not already cached, and answers with its absolute path.

      The public name for what every other call does lazily on its way to a simulator. It exists so a CI image or a provisioning script can front-run the ~19 MB first-call download, at a moment when a slow step is expected, rather than have it land inside the first test that touches a device. Also reachable as npx simgadget prefetch (../cli.ts).

      onProgress is called with the same lines the resolution would otherwise log to nobody: which artifact is being fetched, and where it ended up. Safe to call repeatedly and from several places at once — concurrent callers share one download, and a cached companion is a couple of stat calls.

      Parameters

      • OptionalonProgress: (message: string) => void

      Returns Promise<string>