File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
packages/core/src/singleton/Auth Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -97,12 +97,17 @@ export type AuthConfigUserAttributes = Partial<
9797 Record < AuthStandardAttributeKey , { required : boolean } >
9898> ;
9999
100- export type AuthConfig = StrictUnion <
100+ type AtLeastOne < T , U = { [ K in keyof T ] : Pick < T , K > } > = Partial < T > &
101+ U [ keyof U ] ;
102+
103+ export type cognitoProviderConfig = StrictUnion <
101104 | AuthIdentityPoolConfig
102105 | AuthUserPoolConfig
103106 | AuthUserPoolAndIdentityPoolConfig
104107> ;
105108
109+ export type AuthConfig = AtLeastOne < cognitoProviderConfig > ;
110+
106111type UnionKeys < T > = T extends T ? keyof T : never ;
107112type StrictUnionHelper < T , TAll > = T extends any
108113 ? T & Partial < Record < Exclude < UnionKeys < TAll > , keyof T > , never > >
You can’t perform that action at this time.
0 commit comments