3.6 KiB
Configuration
The package.json file
A Pear project must have a package.json file and a main entry file.
The package.json file must have either a name property or pear object with a name property.
The package.json name field must be lowercase and one word, and may contain letters, numbers, hyphens (-), underscores (_), forward slashes (/) and asperands (@).
The package.json file may also contain a main field, which typically should point to an HTML file. If omitted, index.html or index.js is the default entry file depending on application type.
Any other fields (such as dependencies) may also be present in the package.json file.
The package.json pear object contains application configuration and is exposed via the API as pear.config.options.
Pear versioning is automatic. The package.json file does not require a version field, the version field will be ignored..
The package.json`` pear` field.
pear.name
The name of the application. Overrides package.json name.