Utilização

Prefetch an authenticated image.

tsx
// Prefetch an authenticated image.
import { image, type PrefetchOptions } from 'kuito';

const memoryOnly: PrefetchOptions = { cache: 'memory' };

await image.prefetch(
  { uri: 'https://example.com/avatar.png', headers: { Authorization: 'Bearer token' } },
  memoryOnly,
);

Declaração do tipo

ts
export interface PrefetchOptions {
  /** The caches the image fills; `memory-disk` by default, as on an Image. */
  cache?: PrefetchCache;
}

Membros 1

NomeTipoObrigatórioDescrição
cachePrefetchCacheNãoThe caches the image fills; memory-disk by default, as on an Image.
Gerado a partir das declarações TypeScript públicas: assinaturas, props e predefinições vêm da fonte verificada, as descrições da sua JSDoc. Nenhuma predefinição é inventada.