From 566613be9f49b834bb3ecd64efe59a7565005ce0 Mon Sep 17 00:00:00 2001 From: Mert Sincan Date: Tue, 14 Jan 2025 12:18:50 +0000 Subject: [PATCH] fix: Deprecate UniqueComponentId method in core utils Fixes #7089 --- packages/core/src/utils/UniqueComponentId.js | 5 +++++ packages/core/src/utils/Utils.d.ts | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/packages/core/src/utils/UniqueComponentId.js b/packages/core/src/utils/UniqueComponentId.js index 4e9c242ff..f7786b140 100755 --- a/packages/core/src/utils/UniqueComponentId.js +++ b/packages/core/src/utils/UniqueComponentId.js @@ -1,5 +1,10 @@ import { uuid } from '@primeuix/utils/uuid'; +/** + * @deprecated since v4.3.0. Use `uuid` from @primeuix/utils instead. + * @param {string} prefix + * @return {string} + */ export default function (prefix = 'pv_id_') { return uuid(prefix); } diff --git a/packages/core/src/utils/Utils.d.ts b/packages/core/src/utils/Utils.d.ts index 9128afc45..6b6bc5ded 100644 --- a/packages/core/src/utils/Utils.d.ts +++ b/packages/core/src/utils/Utils.d.ts @@ -16,4 +16,9 @@ export declare class HelperSet { get(parentInstance?: any, slots?: any): any[] | null | undefined; } +/** + * @deprecated since v4.3.0. Use `uuid` from @primeuix/utils instead. + * @param {string} prefix + * @return {string} + */ export declare function UniqueComponentId(prefix?: string): string;