@jskit-ai/agent-docs 0.1.394 → 0.1.396
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/guide/agent/app-extras/assistant-conversation.md +66 -2
- package/guide/agent/app-extras/assistant.md +19 -2
- package/guide/agent/app-extras/mobile-capacitor.md +40 -7
- package/guide/agent/app-setup/upgrading-jskit.md +187 -8
- package/guide/agent/framework/typed-features.md +12 -2
- package/package.json +1 -1
- package/patterns/feature-package/example/booking-engine/package.json +1 -1
- package/patterns/minimal-foundation/example/config/public.js +1 -1
- package/patterns/minimal-foundation/example/eslint.config.mjs +1 -1
- package/patterns/minimal-foundation/example/package.json +4 -4
- package/patterns/shell-foundation/example/config/public.js +1 -1
- package/patterns/shell-foundation/example/eslint.config.mjs +1 -1
- package/patterns/shell-foundation/example/package.json +5 -5
- package/patterns/shell-foundation/example/packages/main/package.json +1 -1
- package/reference/autogen/PATTERN_INDEX.md +41 -41
- package/reference/autogen/packages/assistant-core.md +26 -3
- package/reference/autogen/packages/assistant-runtime.md +7 -0
- package/reference/autogen/tooling/jskit-catalog.md +41 -3
- package/reference/autogen/tooling/jskit-release.md +12 -4
- package/skills/jskit/references/pattern-index.md +41 -41
- package/skills/jskit/references/patterns/app/minimal-foundation/example/config/public.js +1 -1
- package/skills/jskit/references/patterns/app/minimal-foundation/example/eslint.config.mjs +1 -1
- package/skills/jskit/references/patterns/app/minimal-foundation/example/package.json +4 -4
- package/skills/jskit/references/patterns/app/shell-foundation/example/config/public.js +1 -1
- package/skills/jskit/references/patterns/app/shell-foundation/example/eslint.config.mjs +1 -1
- package/skills/jskit/references/patterns/app/shell-foundation/example/package.json +5 -5
- package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/package.json +1 -1
- package/skills/jskit/references/patterns/auth/accounts-hub/example/package.json +3 -3
- package/skills/jskit/references/patterns/auth/oidc-sign-in/example/package.json +2 -2
- package/skills/jskit/references/patterns/auth/supabase-auth/example/package.json +1 -1
- package/skills/jskit/references/patterns/connectors/calendar-cli/example/package.json +5 -5
- package/skills/jskit/references/patterns/crud/crud-feature-package/example/packages/books/package.json +3 -3
- package/skills/jskit/references/patterns/database/mysql-application/example/package.json +2 -2
- package/skills/jskit/references/patterns/database/postgres-application/example/package.json +2 -2
- package/skills/jskit/references/patterns/mobile/android-application/PATTERN.md +34 -6
- package/skills/jskit/references/patterns/realtime/realtime-application/example/package.json +2 -2
- package/skills/jskit/references/patterns/server/feature-package/example/booking-engine/package.json +1 -1
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users/package.json +3 -3
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users-workspace/package.json +6 -6
- package/skills/jskit/references/typed-features.md +12 -2
|
@@ -3,7 +3,7 @@ id: mobile/android-application
|
|
|
3
3
|
title: Capacitor Android application
|
|
4
4
|
summary: Wrap a JSKIT web application in a Capacitor Android shell using native Capacitor and Android commands.
|
|
5
5
|
keywords: android, capacitor, device, mobile, native, shell, webview
|
|
6
|
-
requires: @jskit-ai/mobile-capacitor, @capacitor/android, @capacitor/app, @capacitor/cli
|
|
6
|
+
requires: @jskit-ai/mobile-capacitor, @capacitor/android, @capacitor/app, @capacitor/browser, @capacitor/cli
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# Capacitor Android application
|
|
@@ -26,16 +26,41 @@ Android project.
|
|
|
26
26
|
|
|
27
27
|
## Framework APIs
|
|
28
28
|
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
The package runs on Capacitor 9, and every Capacitor package of the app is on
|
|
30
|
+
that major. Install them by range, so that a later Capacitor major never joins
|
|
31
|
+
them unasked:
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
npm install @jskit-ai/mobile-capacitor \
|
|
35
|
+
@capacitor/android@^9.0.0 @capacitor/app@^9.0.2 @capacitor/browser@^9.0.2 \
|
|
36
|
+
@capacitor/cli@^9.0.0
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
`@capacitor/browser` is a dependency of `@jskit-ai/mobile-capacitor`, which
|
|
40
|
+
opens sign-in with it, but `npx cap sync` builds only the native plugins the
|
|
41
|
+
app's own `package.json` lists, so the app installs it too.
|
|
42
|
+
|
|
43
|
+
Capacitor 9's CLI needs Node.js 24 or newer, and it builds Android with JDK 21
|
|
44
|
+
(as `JAVA_HOME`) and the Android SDK Platform 37. Adapt
|
|
45
|
+
`example/capacitor.config.json` into valid JSON, then use Capacitor directly:
|
|
31
46
|
|
|
32
47
|
```text
|
|
33
|
-
npx cap add android
|
|
34
48
|
npm run build
|
|
49
|
+
npx cap add android
|
|
35
50
|
npx cap sync android
|
|
51
|
+
npx cap doctor android
|
|
36
52
|
npx cap run android
|
|
37
53
|
```
|
|
38
54
|
|
|
55
|
+
`npx cap add android` writes Capacitor 9's project: `compileSdkVersion` and
|
|
56
|
+
`targetSdkVersion` 37 (above Google Play's floor of 36 for new apps and
|
|
57
|
+
updates) and `minSdkVersion` 26 in `android/variables.gradle`, Gradle 9.8.2,
|
|
58
|
+
the Android Gradle Plugin 9.4.1 (which bundles Kotlin), an edge-to-edge
|
|
59
|
+
`MainActivity` and R8 on release builds. Live reload is
|
|
60
|
+
`npx cap run android --url <dev server URL>`. An `android/` that Capacitor 7 or
|
|
61
|
+
8 wrote moves with `npx cap migrate` first: `npm run jskit:check` names what is
|
|
62
|
+
left (`capacitor/*`), and `npm run jskit:update` refuses until then.
|
|
63
|
+
|
|
39
64
|
Use `adb devices`, `adb reverse`, Android Studio, and Gradle directly for device
|
|
40
65
|
selection, tunnelling, diagnostics, and release builds. JSKIT does not wrap
|
|
41
66
|
those tools in another command language.
|
|
@@ -57,11 +82,14 @@ plugins, native permissions, and platform-specific release configuration.
|
|
|
57
82
|
- Browser navigation that leaves the app uses the package's public mobile
|
|
58
83
|
routing capability.
|
|
59
84
|
- Native projects and signing configuration are ordinary app-owned source.
|
|
85
|
+
- Every `@capacitor/*` package of the app is on Capacitor 9, with one
|
|
86
|
+
`@capacitor/core`.
|
|
60
87
|
|
|
61
88
|
## Verification
|
|
62
89
|
|
|
63
|
-
Build the web application, sync Android,
|
|
64
|
-
|
|
90
|
+
Build the web application, sync Android, run `npx cap doctor android` and
|
|
91
|
+
`npm run jskit:check`, launch on an explicit device, test callback routing and
|
|
92
|
+
external links, then build the native release variant.
|
|
65
93
|
|
|
66
94
|
## Avoid
|
|
67
95
|
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
"./shared": "./src/shared/index.js"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@jskit-ai/crud-core": "0.2.
|
|
14
|
-
"@jskit-ai/resource-crud-core": "0.1.
|
|
15
|
-
"@jskit-ai/users-core": "0.2.
|
|
13
|
+
"@jskit-ai/crud-core": "0.2.72",
|
|
14
|
+
"@jskit-ai/resource-crud-core": "0.1.234",
|
|
15
|
+
"@jskit-ai/users-core": "0.2.83"
|
|
16
16
|
},
|
|
17
17
|
"jskit": {
|
|
18
18
|
"kind": "runtime",
|
|
@@ -10,14 +10,14 @@
|
|
|
10
10
|
"./shared": "./src/shared/index.js"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@jskit-ai/crud-core": "0.2.
|
|
14
|
-
"@jskit-ai/resource-crud-core": "0.1.
|
|
15
|
-
"@jskit-ai/users-core": "0.2.
|
|
16
|
-
"@jskit-ai/workspaces-core": "0.2.
|
|
13
|
+
"@jskit-ai/crud-core": "0.2.72",
|
|
14
|
+
"@jskit-ai/resource-crud-core": "0.1.234",
|
|
15
|
+
"@jskit-ai/users-core": "0.2.83",
|
|
16
|
+
"@jskit-ai/workspaces-core": "0.2.83"
|
|
17
17
|
},
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"@jskit-ai/kernel": "0.2.
|
|
20
|
-
"@jskit-ai/resource-runtime": "0.2.
|
|
19
|
+
"@jskit-ai/kernel": "0.2.40",
|
|
20
|
+
"@jskit-ai/resource-runtime": "0.2.65"
|
|
21
21
|
},
|
|
22
22
|
"jskit": {
|
|
23
23
|
"kind": "runtime",
|
|
@@ -1451,6 +1451,16 @@ declares what it runs:
|
|
|
1451
1451
|
}
|
|
1452
1452
|
```
|
|
1453
1453
|
|
|
1454
|
+
- Before any part, `jskit verify` runs the app's JSKIT check, the rules plain
|
|
1455
|
+
`jskit check` runs (`npm run jskit:check`), so no app's Verification leaves
|
|
1456
|
+
its JSKIT drift out. A check that fails ends the run with its findings and
|
|
1457
|
+
their fixes, before any part runs, and records nothing. It reads the
|
|
1458
|
+
modules the app's own check reads: the `--manifest` files of its
|
|
1459
|
+
`jskit:check` script and of each such part. A part whose script is
|
|
1460
|
+
`jskit check` (with only `--manifest` files) is that check, and is not run
|
|
1461
|
+
again; one with its own `env`, or npm `pre`/`post` scripts, is refused, as
|
|
1462
|
+
they would never run. Words for the last part when every part is that check
|
|
1463
|
+
are refused.
|
|
1454
1464
|
- `parts` are the npm scripts of the whole check, run in order as
|
|
1455
1465
|
`npm run <part>`; the first that fails ends the run with its exit status. A
|
|
1456
1466
|
part given as an object gets its `env` settings, and only it does.
|
|
@@ -1469,8 +1479,8 @@ A whole run that passes records exactly what it checked in
|
|
|
1469
1479
|
the installed dependencies of the project and of each checkout (every file's
|
|
1470
1480
|
path, size and modification time under `node_modules`, so an `npm ci` or a
|
|
1471
1481
|
package laid over by hand is another input), the declared settings, Node's
|
|
1472
|
-
version
|
|
1473
|
-
record and runs nothing:
|
|
1482
|
+
version, the JSKIT check (its catalog's version) and the parts. The next
|
|
1483
|
+
`jskit verify` with the same inputs prints the record and runs nothing:
|
|
1474
1484
|
|
|
1475
1485
|
```text
|
|
1476
1486
|
jskit verify: it passed on this exact tree at 2026-12-01T10:00:00.000Z on desktop (the project 36545a948a1b, tree f14b03f42888; public 6ffe6eb08fc3; Node v26.5.0): not run again. Its record is node_modules/.cache/jskit/verify-passes/<key>.json; remove it to run the check again.
|