How to store additional data like phone, location, and address while signing up.
- 0
- Databases
- Flutter
- Storage
- Accounts
do i have to use User Preference,
If its just small amount of information, then yes use the User Preference. But the User Preference has limit of 64KB for the total size, so if it bigger then that creating anouthr collection would be the best
yes its a small amount of data like three or four field with 50 words each
So User Preference well suit you
as i go through doc but not found how to implement.
To get the preference https://appwrite.io/docs/client/account?sdk=web-default#accountGetPrefs
To update https://appwrite.io/docs/client/account?sdk=web-default#accountUpdatePrefs
So you would do something like this
const prefs = await account.getPrefs();
prefs['phone'] = '1234';
await account.updatePrefs(prefs);
but how to create while sign up
For that create a function the listen to the event of user creation and then do something like this
users.updatePrefs('[USER_ID]', {});
Recommended threads
- [SOLVED] curl error Number: 6 — function...
Hello, I invested a lot of time in this error in a fresh install of appwrite 1.8.1 and lasted until fix, this if for helping anyone that can have the same weird...
- createCollection Deprecated
- All My Project is Gone
Hello everyone, please help. Why have all my projects suddenly disappeared? I received a warning via email about one of my projects being paused. When I clicked...