MCPcopy
hub / github.com/callstack/agent-device / readDeviceTarget

Function readDeviceTarget

src/utils/parsing.ts:70–72  ·  view source on GitHub ↗
(record: Record<string, unknown>, key: string)

Source from the content-addressed store, hash-verified

68}
69
70export function readDeviceTarget(record: Record<string, unknown>, key: string): DeviceTarget {
71 return readOptional(record, key, parseDeviceTarget) ?? 'mobile';
72}
73
74export function parseRect(value: unknown): Rect | undefined {
75 if (!isRecord(value)) return undefined;

Callers

nothing calls this directly

Calls 1

readOptionalFunction · 0.85

Tested by

no test coverage detected