mise API - v0.0.0
    Preparing search index...

    Function pluginIndex_load

    • Reads an index from its source.

      Parameters

      • source: PluginIndexSource

        The parsed source.

      • fetcher: {
            (input: URL | RequestInfo, init?: RequestInit): Promise<Response>;
            (input: string | URL | Request, init?: RequestInit): Promise<Response>;
        } = fetch

        The fetch used for GitHub; the global one by default.

          • (input: URL | RequestInfo, init?: RequestInit): Promise<Response>
          • Parameters

            • input: URL | RequestInfo
            • Optionalinit: RequestInit

            Returns Promise<Response>

          • (input: string | URL | Request, init?: RequestInit): Promise<Response>
          • Parameters

            • input: string | URL | Request
            • Optionalinit: RequestInit

            Returns Promise<Response>

      Returns Promise<Result<PluginIndex>>

      The index, or an error on the error stack (the fetch failed, the path is not there, the archive is unreadable).

      const loaded: Result<PluginIndex> = await pluginIndex_load({ kind: 'host', path: './plugins' });