setPreference abstract method

Future<void> setPreference(
  1. String key,
  2. dynamic value
)

Saves a single preference to remote storage.

key is the unique identifier for the preference. value is the value to store (String, bool, int, double, etc.).

Use toTypedValue() to convert the value to a storable format.

Implementation

Future<void> setPreference(String key, dynamic value);