Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .changeset/6342-dead-migration-guide-pointers.md
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
---
'@object-ui/core': patch
---

Two deprecation warnings pointed at `MIGRATION_GUIDE.md`, a file deleted from the
repository in `8c5d20455` (objectui#6342).

`Registry.register()`'s missing-namespace warning now points at the live docs page
that documents namespaced registration
(`/docs/guide/plugin-development#namespaced-registration`) instead of the deleted
guide. `ValidationEngine`'s function-based-condition warning drops its `See:` line
entirely: the deleted guide covered component namespaces and lazy field
registration and never documented conditions at all, so that pointer was
misdirected as well as dead, and the warning already carries the complete
before/after migration inline.

Both are console messages shipped to application developers, so neither can use
the immutable `git show <sha>^:<path>` provenance form objectui#6275 used for a
docblock — a reader of the npm package has no repository to run it against.
2 changes: 1 addition & 1 deletion packages/core/src/registry/Registry.ts
Original file line numberDiff line numberDiff line change
Expand Up@@ -225,7 +225,7 @@ export class Registry<T = any> {
` registry.register('${type}', MyComponent);\n\n` +
` // After:\n` +
` registry.register('${type}', MyComponent, { namespace: 'my-plugin' });\n\n` +
` See: https://github.com/objectstack-ai/objectui/blob/main/MIGRATION_GUIDE.md`
` See: https://www.objectui.org/docs/guide/plugin-development#namespaced-registration`
);
}

Expand Down
3 changes: 1 addition & 2 deletions packages/core/src/validation/validation-engine.ts
Original file line numberDiff line numberDiff line change
Expand Up@@ -407,8 +407,7 @@ export class ValidationEngine {
' // Before (deprecated):\n' +
' { condition: (values) => values.age > 18 }\n\n' +
' // After:\n' +
' { condition: { field: "age", operator: ">", value: 18 } }\n\n' +
' See: https://github.com/objectstack-ai/objectui/blob/main/MIGRATION_GUIDE.md'
' { condition: { field: "age", operator: ">", value: 18 } }'
);
return false; // Security: reject function-based conditions
}
Expand Down
Loading