Preferences (Xamarin.Essentials API of the Week)

Sign in to queue

The Discussion

  • User profile image
    toumir

    Awesome! thank you for sharing

    how can persist preferences even after uninstalling App ?

    thanks again

  • User profile image
    Eglem maxime

    @toumir, because essential use native Api. Your data is managed by the OS. Preference can be automatically saved in apple cloud without doing anything. Meaning if your app is delete and reinstall via the cloud. Your preferences are saved as well. Awesome right? :)

  • User profile image
    JJoel
    Why would anyone use Preferences over Application.Current.Properties? Seems redundant!
  • User profile image
    James​Montemagno
    I get this question a lot, so here it is from a recent issue opened up. This plugin saves specific properties directly to each platforms native settings APIs (NSUserDefaults, SharedPreferences, etc). This ensures the fastest, most secure, and reliable creation and editing settings per application. Additionally, it works with any Xamarin application, not just Xamarin.Forms.

    App.Current.Properties actually serializes and deserializes items to disk.

Add Your 2 Cents