Skip to main content

Function: detectHost()

function detectHost(): HostIdentity;

Defined in: host.ts:26

Detect where the SDK is running. A DOM document plus location.origin means a browser (PWA, <rasd-form>, iframe — inside an iframe the frame's own origin, which is what location.origin already is); everything else is Node/SSR/CI. React Native is never detected: @rasd/license has no platform APIs, so the host passes appId to createLicense explicitly (docs/15 §4.2) and the handle constructs the native identity itself.

Returns

HostIdentity