Remove 4.7 based features, added some comments

This commit is contained in:
Convly 2022-05-31 10:08:12 +02:00
parent e62efa2a6a
commit ee211466ce
3 changed files with 11 additions and 7 deletions

View File

@ -41,6 +41,9 @@ declare global {
*/
type ComponentUIDs = KeysBy<Schemas, ComponentSchema>;
/**
* Global shorthand to access the `StrapiInterface` type
*/
type Strapi = StrapiInterface;
}

View File

@ -57,7 +57,7 @@ export type GetAttributeValue<T extends Attribute> =
| GetUIDAttributeValue<T>;
export type GetAttributeValueByKey<T extends SchemaUID, U extends GetAttributesKey<T>> = GetAttribute<T, U
> extends infer P extends Attribute ? GetAttributeValue<P>:never;
> extends infer P ? P extends Attribute ? GetAttributeValue<P> : never : never;
export type GetAttributesValues<T extends SchemaUID> = {
// Handle required attributes

View File

@ -1,3 +1,4 @@
export * from './core';
export * from './factories';
export * from './utils'
export * as utils from './utils'
export * as factories from './factories';