Skip to content

Latest commit

 

History

History
43 lines (33 loc) · 1.47 KB

File metadata and controls

43 lines (33 loc) · 1.47 KB

JavaScript

Recommended Setup

Use [pnpm] because it supports specifying a dependency which is subdirectory of a GitHub repository, which is necessary since LLRT doesn't have an npm package for its types:

// package.json
{
  "devDependencies": {
    "llrt-types": "github:awslabs/llrt#path:/types",
    // ...
  }
}

Make sure your tsconfig.json has the types property set to llrt-types:

// tsconfig.json
{
  "compilerOptions": {
    "types": ["llrt-types"],
    // ...
  }
}

Recommended Packages

  • nano-spawn-compat - A more ergonomic child_process.spawn that works in LLRT.
  • bplist-lossless - A binary plist parser specifically tailored for edits by avoiding loss of precision during parsing and re-serialization.
  • doctor-json - A JSON editor that preserves all existing formatting/comments
  • keycode-ts2 - A TypeScript port of the Rust keycode crate which uses the Chromium keycode names as the source of truth (Chords uses these keycode names as the source of truth).

chord

The built-in chord module also exposes:

export function setAppNeedsRelaunch(bundleId: string, needsRelaunch: boolean): void;

This marks or clears an app in the settings UI and gives the user a one-click relaunch button.