Aller au contenu

ConfigAPI

Ce contenu n’est pas encore disponible dans votre langue.

struct ConfigAPI

Config resolution. Obtained from FrakClient.config.

Conforms to Swift.Sendable

Defined in: Sources/FrakSDK/ConfigAPI.swift:4

var current: FrakResolvedConfig? { get async }

The most recently resolved config, or nil before the first resolve.

var updates: AsyncStream<FrakResolvedConfig> { get async }

Multicast. Emits on a network resolve that changed the config, and replays the last such value; a warm start served from a fresh cache emits nothing, so read current first.

func resolve(forceRefresh: Bool = false) async throws -> FrakResolvedConfig

Stale-while-revalidate cache; forceRefresh still respects failure backoff.