MCPcopy Index your code
hub / github.com/callstack/agent-device / deviceFieldsFromPublicPlatform

Function deviceFieldsFromPublicPlatform

src/kernel/device.ts:111–118  ·  view source on GitHub ↗
(platform: PublicPlatform)

Source from the content-addressed store, hash-verified

109 * leaves `appleOs` unset so the target-based inference still distinguishes tvOS.
110 */
111export function deviceFieldsFromPublicPlatform(platform: PublicPlatform): {
112 platform: Platform;
113 appleOs?: AppleOS;
114} {
115 if (platform === 'macos') return { platform: 'apple', appleOs: 'macos' };
116 if (platform === 'ios') return { platform: 'apple' };
117 return { platform };
118}
119
120/**
121 * The tvOS Apple-OS leaf predicate. tvOS is modeled as the `ios` platform with a

Callers 3

deviceForLeaseMethod · 0.90
resolveSelectedDeviceFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected