type alias StoragePluginOptions
Since 0.1.0

Top-level options passed to StoragePlugin: a union discriminated on provider, so each backend's options are checked against that backend's own shape.

The memory arm keeps provider OPTIONAL, so an omitted provider still means 'memory' and StoragePlugin() is unchanged.

Before this was discriminated, one unknown key made the compiler report EVERY property of the literal as not assignable to type 'never' and never named the offending one — the union's first member was Record<string, never>, which accepts any object shape while requiring every property to be never, so a literal matching no other member bound to it. Discriminating also makes a missing bucket or containerName a compile error under the arm that requires it, rather than something only the running backend notices.

Definition

Usage

import { type StoragePluginOptions } from "storage-plugin/src/index.ts";