[Bug]: Capacitor Preferences API not worked when Trash the App.
chaklasiyanikunj opened this issue · comments
Capacitor Version
I read this documentation, which is capacitor JS provided
/*
* this function is used for the set Value
*/
async setUser(data: any) {
await Preferences.set({
key: 'value',
value: JSON.stringify(data)
});
}
/*
* this function is used for the get-Value
*/
async getUser() {
const user: any = await Preferences.get({ key: 'value' });
this.UsersDetails = user.value;
}
This is working fine when my app is running in the background. When I trash my app in the background and call for getUser(). It's giving a null value. It's not work.
Can anyone suggest if I am missing anything, or is there any other way available to Store the data in Capacitor JS?
Other API Details
No response
Platforms Affected
- iOS
- Android
- Web
Current Behavior
It works with the When I app in the background.
Expected Behavior
It needs to work with me when I trash the app.
Project Reproduction
Angular
Additional Information
No response
This issue needs more information before it can be addressed. In particular, the reporter needs to provide a minimal sample app that demonstrates the issue. If no sample app is provided within 15 days, the issue will be closed.
Please see the Contributing Guide for how to create a Sample App.
Thanks! Ionitron 💙
It's solved