mirror of
https://github.com/aljazceru/pear-docs.git
synced 2025-12-18 06:54:22 +01:00
Pear release 1.8.0 docs (#162)
* Add `Pear.badge(count)` documentation Picked `null` to be the documented way to display a plain dot given it coerces to `0`, so passes the `Number.isInteger(count)` check, and has the same behavior in plain electron. * Add `pear.stage.prefetch` to Application Configuration * Update `stage` subcommand help output The `truncate` was added since https://github.com/holepunchto/pear/commit/85892a6a#diff-c218df6a550b0f3a42a2879e83f3ce2281061a1e79123d2a6d610d62d5f63bd8R79 but was missing. * Add `pear.userAgent` to Application Configuration * Adjust info about warmup in the guides * Clarify that `pear.userAgent` will not change Sidecar requests
This commit is contained in:
@@ -433,6 +433,14 @@ The `listener` function is called for every incoming wakeup with a `wakeup` obje
|
||||
|
||||
Also returns a [`streamx`](https://github.com/mafintosh/streamx) `Readable`) stream.
|
||||
|
||||
### `Pear.badge(count <Integer|null>) => Promise<Boolean>`
|
||||
|
||||
Set the badge number for the application on desktop for Linux & MacOS. Setting the `count` to `0` will hide the badge while `null` will display a plain dot on MacOS only.
|
||||
|
||||
Returns a `Boolean` promise for whether the call succeeded.
|
||||
|
||||
Desktop Applications only.
|
||||
|
||||
### `const win = new Pear.Window(entry <String>, options <Object>)`
|
||||
|
||||
Desktop Applications only.
|
||||
|
||||
@@ -48,7 +48,8 @@ Outputs diff information and project link.
|
||||
```
|
||||
--json Newline delimited JSON output
|
||||
--dry-run|-d Execute a stage without writing
|
||||
--ignore Comma separated file path ignore list
|
||||
--ignore <list> Comma separated file path ignore list
|
||||
--truncate <n> Advanced. Truncate to version length n
|
||||
--name Advanced. Override app name
|
||||
--no-ask Suppress permissions dialogs
|
||||
--help|-h Show help
|
||||
|
||||
@@ -153,13 +153,23 @@ Note that this is only for requests that the Pear app makes itself such as loadi
|
||||
}
|
||||
```
|
||||
|
||||
### `pear.userAgent <string>` (default: `Pear ${Pear.#state.id}`)
|
||||
|
||||
User Agent to use when Pear makes web requests. Pear will use the default `userAgent` when making requests to the Sidecar.
|
||||
|
||||
Desktop Applications only.
|
||||
|
||||
### `pear.stage <Object>`
|
||||
|
||||
Staging configuration options.
|
||||
|
||||
#### `pear.stage.entrypoints <Array>`
|
||||
|
||||
An array of entrypoints as staging start-points in addition to (deduped) main entry point.
|
||||
An array of entrypoint paths as staging start-points in addition to (deduped) main entry point.
|
||||
|
||||
#### `pear.stage.prefetch <Array>`
|
||||
|
||||
An array of file paths to the warmup during staging in addition to all entry points. This is useful for loading assets needed to start the application quickly.
|
||||
|
||||
#### `pear.stage.ignore <Array>`
|
||||
|
||||
|
||||
Reference in New Issue
Block a user