Configuration: rayact.config.json
Schema for rayact.config.json. Fields omitted fall back to built-in defaults; only set a field to override a default.
Add the $schema key for editor autocomplete:
json
{
"$schema": "./node_modules/@rayact/dev-server/schema/rayact.config.schema.json",
"rayactAppKey": "my-app",
"entry": "src/App.tsx",
"platform": "desktop"
}Fields
| Field | Type | Description |
|---|---|---|
name | string | Cross-platform display name used by generated clients and dev-server discovery. |
rayactAppKey | string | Stable app identifier. Also seeds the container-pack obfuscation key. |
entry | string | Entry source file (e.g. src/App.tsx), relative to the project root. |
platform | desktop | android | ios | web | Deprecated. Use command flags such as --desktop, --android, --ios, or --web. |
devServer | object | |
devServer.host | string | |
devServer.port | integer | |
devServer.cdpPort | integer | |
devServer.strictPort | boolean | Fail if devServer.port is already in use instead of picking the next free port. |
android | object | |
android.package | string | Deprecated Android application id alias. Use packageName. |
android.projectDir | string | Gradle project dir (contains gradlew), relative to project root. |
android.activity | string | Optional fully qualified Android activity class. Defaults to the prebuilt Rayact host activity. |
android.appName | string | Deprecated Android-only display name. Use top-level name. |
android.packageName | string | Android application id used by prebuild, install, and launch. |
android.icon | string | |
ios | object | |
ios.projectDir | string | |
ios.bundleId | string | iOS product bundle identifier used by prebuild, install, and launch. |
linking | object | Application deep-link schemes generated into native platform projects. |
linking.schemes | string[] | |
router | object | File-based routing (@rayact/router) options. |
router.appDir | string | Routes directory relative to the project root. Default "app". |
nativeModules | any[] | Installed native modules autolink automatically. Entries may disable or configure a package. Legacy name/lib/jsPackage objects are accepted with a warning through 0.0.x. |
transform | object | Per-build-mode transforms. Defaults: dev=false, debug=false, release=true. |
transform.minify | object | |
transform.minify.dev | boolean | |
transform.minify.debug | boolean | |
transform.minify.release | boolean | |
transform.bytecode | object | |
transform.bytecode.dev | boolean | |
transform.bytecode.debug | boolean | |
transform.bytecode.release | boolean | |
pack | object | Container (.rayactpack) packaging options for release/platform builds. |
pack.include | string[] | Extra (non-standard) file globs to opt into the pack, relative to the project root. |
pack.obfuscate | boolean | XOR-obfuscate pack entries with a key derived from rayactAppKey. Default false. |
pack.maxChunkSize | integer | Max bytes per pack chunk before splitting. Default 104857600 (100 MB). |
Transforms default to
dev=false, debug=false, release=true. Development and debug transforms can be overridden. Release bytecode is mandatory; a legacytransform.bytecode.release=falsevalue is accepted but ignored.