@jskit-ai/agent-docs 0.1.290 → 0.1.292
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-setup/existing-application-migration.md +1 -1
- package/guide/agent/framework/data-access.md +309 -22
- package/guide/agent/framework/material-3.md +40 -39
- package/guide/agent/framework/sanity-checks.md +19 -12
- package/package.json +1 -1
- package/patterns/feature-package/example/booking-engine/package.json +1 -1
- package/patterns/minimal-foundation/example/package.json +4 -4
- 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 +38 -38
- package/reference/autogen/packages/agent-runtime.md +4 -0
- package/reference/autogen/packages/crud-core.md +1 -1
- package/reference/autogen/packages/kernel.md +1 -1
- package/reference/autogen/packages/resource-core.md +1 -0
- package/reference/autogen/packages/resource-runtime.md +39 -3
- package/reference/autogen/packages/workspaces-core.md +0 -2
- package/reference/autogen/tooling/jskit-catalog.md +30 -10
- package/skills/jskit/references/data-access.md +309 -22
- package/skills/jskit/references/existing-application-migration.md +1 -1
- package/skills/jskit/references/heuristics/ui-testing.md +6 -3
- package/skills/jskit/references/material-3.md +40 -39
- package/skills/jskit/references/pattern-index.md +38 -38
- package/skills/jskit/references/patterns/app/minimal-foundation/example/package.json +4 -4
- 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 +4 -4
- 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/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/sanity-checks.md +19 -12
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"test": "jskit test --databases"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@jskit-ai/database-runtime": "0.1.
|
|
13
|
-
"@jskit-ai/database-runtime-postgres": "0.1.
|
|
12
|
+
"@jskit-ai/database-runtime": "0.1.266",
|
|
13
|
+
"@jskit-ai/database-runtime-postgres": "0.1.263"
|
|
14
14
|
}
|
|
15
15
|
}
|
|
@@ -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.22",
|
|
14
|
+
"@jskit-ai/resource-crud-core": "0.1.208",
|
|
15
|
+
"@jskit-ai/users-core": "0.2.23"
|
|
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.22",
|
|
14
|
+
"@jskit-ai/resource-crud-core": "0.1.208",
|
|
15
|
+
"@jskit-ai/users-core": "0.2.23",
|
|
16
|
+
"@jskit-ai/workspaces-core": "0.2.23"
|
|
17
17
|
},
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"@jskit-ai/kernel": "0.2.
|
|
20
|
-
"@jskit-ai/resource-runtime": "0.2.
|
|
19
|
+
"@jskit-ai/kernel": "0.2.17",
|
|
20
|
+
"@jskit-ai/resource-runtime": "0.2.19"
|
|
21
21
|
},
|
|
22
22
|
"jskit": {
|
|
23
23
|
"kind": "runtime",
|
|
@@ -4,9 +4,9 @@
|
|
|
4
4
|
|
|
5
5
|
Before calling a list, a save, a test, a refactor, a screen or a deployment
|
|
6
6
|
done, measure what it costs and does, judge whether that is sane, and fix the
|
|
7
|
-
cause when it is not. This page holds JSKIT's part: the pitfalls
|
|
7
|
+
cause when it is not. This page holds JSKIT's part: the pitfalls its own
|
|
8
8
|
packages cause, then the JSKIT call, helper or setting that applies each
|
|
9
|
-
check,
|
|
9
|
+
check, and what it catches.
|
|
10
10
|
|
|
11
11
|
## JSKIT's own pitfalls
|
|
12
12
|
|
|
@@ -67,10 +67,14 @@ expects the relationship id or an unselected field never gets it.
|
|
|
67
67
|
### Every row
|
|
68
68
|
|
|
69
69
|
- A handle's `query()` answers one page and refuses a missing or oversized
|
|
70
|
-
`page.size`,
|
|
71
|
-
|
|
72
|
-
|
|
70
|
+
`page.size`, where json-rest-api would cut the list silently. A read its
|
|
71
|
+
callers treat as complete uses `queryAll()`, or the missing rows vanish from
|
|
72
|
+
every picker and delivery built on it
|
|
73
73
|
([Reads](data-access.md#reads-shaped-for-the-screen)).
|
|
74
|
+
- A grouped `aggregate()` answers every group or throws
|
|
75
|
+
`RESOURCE_GROUP_LIMIT`; past `pageLimits().request` groups, page it with
|
|
76
|
+
`page: { size, number }`
|
|
77
|
+
([The handle's calls](data-access.md#the-handle-s-calls)).
|
|
74
78
|
- A lookup by a unique key matches at most one row: `get(id)`, or a `query()`
|
|
75
79
|
of page size 1.
|
|
76
80
|
|
|
@@ -79,12 +83,11 @@ expects the relationship id or an unselected field never gets it.
|
|
|
79
83
|
- Count a path's queries with `expectFlatQueries()` from
|
|
80
84
|
`@jskit-ai/resource-runtime/test`, or `countQueries()` from
|
|
81
85
|
`@jskit-ai/database-runtime/server/testDatabases`, at a few rows and at a
|
|
82
|
-
realistic number;
|
|
86
|
+
realistic number; it should follow tables and pages, not rows
|
|
83
87
|
([Tests](data-access.md#tests)).
|
|
84
88
|
- A JSON:API read adds a few lookup and visibility queries per page and per
|
|
85
|
-
relationship field, and
|
|
86
|
-
|
|
87
|
-
rows, so `expectFlatQueries` passes them.
|
|
89
|
+
relationship field, and one statement per relationship for its related ids.
|
|
90
|
+
Both follow pages, not rows, so `expectFlatQueries` passes them.
|
|
88
91
|
- A handle's `get()` or `query()`, or a service `get`, inside a loop is the
|
|
89
92
|
usual per-row read; batch it with an id-list filter through `queryAll()` or
|
|
90
93
|
`include`, grouped with `Map.groupBy()`
|
|
@@ -108,11 +111,15 @@ expects the relationship id or an unselected field never gets it.
|
|
|
108
111
|
`DB_NAME`, because tests write and delete rows and would destroy the
|
|
109
112
|
developer's data. A skip for want of a test database is a failure.
|
|
110
113
|
- Test databases restore a stored snapshot checked by a digest of the
|
|
111
|
-
migration and seed sources, and the harness
|
|
112
|
-
|
|
114
|
+
migration and seed sources, and the harness times each preparation phase,
|
|
115
|
+
so slow preparation shows ([Test databases are prepared
|
|
113
116
|
once](typed-features.md#test-databases-are-prepared-once),
|
|
114
117
|
[integration test
|
|
115
118
|
databases](database-layer.md#integration-test-databases)).
|
|
119
|
+
- A component's content and states are checked in a Vitest component test;
|
|
120
|
+
a browser check is an assertion in the Playwright spec that already reaches
|
|
121
|
+
that screen. Every Playwright run ends with its 10 slowest tests: compare a
|
|
122
|
+
new test's time, and the suite's, before and after.
|
|
116
123
|
|
|
117
124
|
### Inputs and access
|
|
118
125
|
|
|
@@ -135,7 +142,7 @@ Before changing a JSKIT feature, list where its behaviour lives, with the test
|
|
|
135
142
|
that covers each item, and walk the list again after: routes, actions and
|
|
136
143
|
their input schemas, row policies, CRUD fields, lookups and hooks, placements
|
|
137
144
|
and navigation meta, messages and their codes, events, jobs and migrations.
|
|
138
|
-
|
|
145
|
+
A consolidation drops behaviour there without a failing build.
|
|
139
146
|
|
|
140
147
|
### Changes others depend on
|
|
141
148
|
|