mirror of
https://github.com/aljazceru/pear-docs.git
synced 2025-12-18 06:54:22 +01:00
config pear.builtinsMap
This commit is contained in:
@@ -22,6 +22,29 @@ Pear versioning is automatic. The `package.json` file does **not** require a ver
|
|||||||
|
|
||||||
The name of the application. Overrides `package.json` `name`.
|
The name of the application. Overrides `package.json` `name`.
|
||||||
|
|
||||||
|
### `pear.builtinsMap` <Object> <small>Terminal Applications Only</small>
|
||||||
|
|
||||||
|
Terminal Applications run on the [`bare`](https://github.com/holepunchto/bare) JavaScript runtime,
|
||||||
|
which has a very small core so code with expects say, an `fs` module will throw MODULE_NOT_FOUND
|
||||||
|
unless that namespace is mapped to an installed module.
|
||||||
|
|
||||||
|
Provide an object that maps builtin dependency namespaces to installed modules.
|
||||||
|
|
||||||
|
An example `package.json`:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"name": "example",
|
||||||
|
"pear": {
|
||||||
|
"builtinsMap": {
|
||||||
|
"fs": "bare-fs"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
> In future this option may also apply to Desktop Applications.
|
||||||
|
|
||||||
### `pear.gui` <Object>
|
### `pear.gui` <Object>
|
||||||
|
|
||||||
Graphical User Interface configuration options.
|
Graphical User Interface configuration options.
|
||||||
|
|||||||
Reference in New Issue
Block a user