Skip to content

Root API

The root API contains runtime availability, bridge readiness, and a few cross-cutting helpers.

Most plugin code should prefer specific namespaces such as desktop, jobs, deps, or qc. Use root-level helpers for availability checks and advanced integration points.

Members

MemberTypeDescription
isAvailablebooleanWhether the Liatir bridge is available.
apiVersionstringBridge API version.
readyPromise<true>Resolves when the bridge is ready.
isDesktopbooleanWhether the current runtime is desktop Liatir.
onReady(callback)(callback: Function) => voidRuns a callback when the bridge is ready.
openBrowser(url)(url: string) => Promise<void>Opens a URL in the external browser.
invoke(cmd, payload)generic promiseLow-level command invocation.

Example

ts
import { Liatir, isLiatirAvailable } from 'liatir';

if (!isLiatirAvailable()) {
  throw new Error('This feature must run inside Liatir.');
}

await Liatir.ready;

Notes

Use openBrowser for external links and invoke only when a typed namespace does not expose the feature you need.

Liatir — powerful bioinformatics on your machine.

By using this app, you agree to our Privacy Policy and Terms of Service.