Skip to content

configureFoundation

See the Configuration guide for the full reference.

Quick Reference

ts
import { configureFoundation } from '@zyno-io/mobile-foundation-rn';
import type { FoundationConfig, ColorScheme, CreateColorScheme } from '@zyno-io/mobile-foundation-rn';
ExportTypeDescription
configureFoundation(config: FoundationConfig) => voidInitialize the library
FoundationConfigtypeConfiguration interface
ColorSchemetypeColor scheme key-value map
CreateColorScheme<T>typeHelper to extend ColorScheme with custom key names (T is a string union)

INFO

getFoundationConfig() is available as an internal import from ./config but is not re-exported from the library's public API.

Side Effects

configureFoundation also:

  1. Configures MobX (enforceActions: 'never')
  2. Schedules SentryHelper.init() via setImmediate
  3. Starts AppStateTracker (logs app lifecycle events)