You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While upgrading from v2 to v3 I noticed that Typescript started to complain about my metadata in a createUser call being an object when this is expected to be a string.
When stringifying the object, the calls to Auth0 started to fail because Auth0 API expects an object.
The following error is returned from the Auth0 call:
I think this is just a type mismatch for the metadata property in the CreateUserOptions because keeping it as an object (and suppressing the TS error) works as expected.
Reproduction
Use the createUser method to call Auth0 signup
Pass an object to the metadata property in that call
TS will complain that the type for metadata is expected to be string | undefined
Try to use JSON.stringify in your object to match the type
Request to Auth0 will fail because it expects an object and not a string
Additional context
No response
react-native-auth0 version
3.0.1
React Native version
0.68.7
Expo version
No response
Platform
Android, iOS
Platform version(s)
N/A
The text was updated successfully, but these errors were encountered:
Checklist
Description
Hi,
While upgrading from v2 to v3 I noticed that Typescript started to complain about my
metadata
in acreateUser
call being an object when this is expected to be a string.When stringifying the object, the calls to Auth0 started to fail because Auth0 API expects an object.
The following error is returned from the Auth0 call:
I think this is just a type mismatch for the
metadata
property in theCreateUserOptions
because keeping it as an object (and suppressing the TS error) works as expected.Reproduction
createUser
method to call Auth0 signupmetadata
property in that callmetadata
is expected to bestring | undefined
JSON.stringify
in your object to match the typeAdditional context
No response
react-native-auth0 version
3.0.1
React Native version
0.68.7
Expo version
No response
Platform
Android, iOS
Platform version(s)
N/A
The text was updated successfully, but these errors were encountered: