Merge pull request #7913 from backstage/jhaals/core-plugin-deps
core-plugin-api: Deprecate unused types
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/core-plugin-api': patch
|
||||
---
|
||||
|
||||
Deprecate unused ApiRef types
|
||||
@@ -142,7 +142,7 @@ export type ApiRefConfig = {
|
||||
description?: string;
|
||||
};
|
||||
|
||||
// @public
|
||||
// @public @deprecated
|
||||
export type ApiRefsToTypes<
|
||||
T extends {
|
||||
[key in string]: ApiRef<unknown>;
|
||||
@@ -151,7 +151,7 @@ export type ApiRefsToTypes<
|
||||
[key in keyof T]: ApiRefType<T[key]>;
|
||||
};
|
||||
|
||||
// @public
|
||||
// @public @deprecated
|
||||
export type ApiRefType<T> = T extends ApiRef<infer U> ? U : never;
|
||||
|
||||
// @public
|
||||
|
||||
@@ -35,6 +35,7 @@ export type AnyApiRef = ApiRef<unknown>;
|
||||
* Transforms ApiRef type into its inner API type.
|
||||
*
|
||||
* @public
|
||||
* @deprecated unused type.
|
||||
*/
|
||||
export type ApiRefType<T> = T extends ApiRef<infer U> ? U : never;
|
||||
|
||||
@@ -51,6 +52,7 @@ export type TypesToApiRefs<T> = { [key in keyof T]: ApiRef<T[key]> };
|
||||
* Reverse type transform of {@link TypesToApiRefs}.
|
||||
*
|
||||
* @public
|
||||
* @deprecated unused type.
|
||||
*/
|
||||
export type ApiRefsToTypes<T extends { [key in string]: ApiRef<unknown> }> = {
|
||||
[key in keyof T]: ApiRefType<T[key]>;
|
||||
|
||||
Reference in New Issue
Block a user