Reference
Authoritative descriptions of Pear's CLI, runtime APIs, configuration, building blocks, and helper modules. Use this when you need a fact, not a tutorial.
Reference is the technical description of how Pear works. It's information-oriented: comprehensive, accurate, and dry. Use it to look up a flag, an API signature, or a configuration field.
If you're trying to accomplish a specific task, see How To. For the design rationale, see About Pear.
In this section
Pear runtime
- Pear CLI—covers
pear run,pear stage,pear seed,pear release, and every flag. pear-runtimemodule—the JavaScript API exposed inside a running Pear app.- Configuration—every key in
package.json'spearblock. - Pear API (deprecated)—the older direct-access API. Use the runtime module instead.
Bare
The runtime Pear is built on, and the kit for embedding it in native apps:
- Bare runtime API—the
Bareglobal: process properties, lifecycle, addons, threads, IPC. - Bare CLI—run a script or REPL with the
barecommand. - Bare Kit—the Worklet and IPC API for iOS, Android, and React Native.
Per-module API references (also linked from the Bare modules catalog): bare-fs, bare-os, bare-stream, bare-tcp, bare-fetch, bare-crypto, bare-subprocess, bare-rpc, bare-sqlite, bare-broadcast-channel, bare-sdl, bare-module-resolve, bare-module-traverse, bare-addon-resolve, bare-bluetooth-android, bare-bluetooth-apple, bare-module, bare-url, bare-atomics, bare-pipe, bare-semver, bare-form-data, bare-channel, bare-tls, bare-console, bare-structured-clone, bare-ipc, bare-inspector, bare-make, bare-prom-client, bare-posix, bare-mdns-discovery, bare-sidecar, bare-union-bundle, bare-mime, bare-apk.
CI & release
- Desktop release npm scripts—the common
package.jsonscripts in Pear Electron desktop repos. - Holepunch GitHub Actions—the reusable composite actions in
holepunchto/actionsfor building, signing, publishing, and recovering Pear apps and modules. - pear-ci GitHub Action—staging a Pear app from CI into a
pear://link with thepear-ciaction.
Module catalog
- Modules—the
pear-*libraries: application, UI, common, developer, integration. - Bare modules—the
bare-*runtime modules underpinning Pear.
Building blocks
The core peer-to-peer primitives Pear is built on:
Helpers
Higher-level utilities that combine the building blocks:
Tools
CLI utilities built on Pear: