Skip to content

Commit a069bdb

Browse files
committed
docs(skills): name the pluralLabel exception to "an extension can add but never remove"
An object extension that sets a new `label` and no `pluralLabel` clears the base's `pluralLabel` from the served object. The Object Extension Model sentence now names that exception. The token cost is paid in the same file by dropping the Lifecycle Hooks pointer's duplicate link to references/data-hooks.md. Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016WV4cx4foyi3wUWBrRHCmF
1 parent badf24d commit a069bdb

2 files changed

Lines changed: 13 additions & 2 deletions

File tree

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
docs(skills): an object extension that renames `label` without `pluralLabel` clears the base plural
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
`objectstack-data` § Object Extension Model still says an extension can add but never remove, and now names the one exception the object fold has: an extension that sets a new `label` and no `pluralLabel` takes the base's `pluralLabel` off the served object unless a tenant authored that plural, so an author who renames an object sets both to keep a plural. An extension that repeats the label it extends removes nothing. The Lifecycle Hooks pointer line drops its second link to `references/data-hooks.md`, which the catalog list and the backfill paragraph already link. No schema, key or behaviour changes.

‎skills/objectstack-data/SKILL.md‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ See [rules/indexing.md](./rules/indexing.md) for composite indexes, unique scope
337337
refused), the retired `type` / `partial`, and partial / gin / gist indexes at the
338338
database layer.
339339

340-
→ Moved verbatim to [references/examples-objects.md](./references/examples-objects.md) § Lifecycle Hooks (the hooks reference itself is [references/data-hooks.md](./references/data-hooks.md)).
340+
→ Moved verbatim to [references/examples-objects.md](./references/examples-objects.md) § Lifecycle Hooks.
341341

342342
---
343343

@@ -346,7 +346,8 @@ database layer.
346346
To add fields/validations/indexes to an object you do not own, author
347347
`defineObjectExtension({ extend, fields, fieldPatches, priority })` and register it on
348348
`defineStack({ objectExtensions: [...] })`. `priority` sets merge order (default
349-
`200`, range `0–999`); an extension can add but never remove. ⛔ Not the same key
349+
`200`, range `0–999`); an extension can add but never remove, except that a new
350+
`label` without `pluralLabel` clears the base plural unless a tenant authored it (set both). ⛔ Not the same key
350351
as object-level `ownership` (the record-ownership enum
351352
`'user' | 'business_unit' | 'org' | 'none'`). Schema:
352353
`node_modules/@objectstack/spec/src/data/object.zod.ts` (`ObjectExtensionSchema`).

0 commit comments

Comments
 (0)