diff --git a/.changeset/6342-dead-migration-guide-pointers.md b/.changeset/6342-dead-migration-guide-pointers.md new file mode 100644 index 0000000000..a4a89c9c2a --- /dev/null +++ b/.changeset/6342-dead-migration-guide-pointers.md @@ -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 ^:` provenance form objectui#6275 used for a +docblock — a reader of the npm package has no repository to run it against. diff --git a/packages/core/src/registry/Registry.ts b/packages/core/src/registry/Registry.ts index c55c781a29..a297282163 100644 --- a/packages/core/src/registry/Registry.ts +++ b/packages/core/src/registry/Registry.ts @@ -225,7 +225,7 @@ export class Registry { ` 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` ); } diff --git a/packages/core/src/validation/validation-engine.ts b/packages/core/src/validation/validation-engine.ts index ed90000666..d78becae9c 100644 --- a/packages/core/src/validation/validation-engine.ts +++ b/packages/core/src/validation/validation-engine.ts @@ -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 }