DataStorePreferencesStorage
Parameters
T
The type of the object to be stored. Must be serializable.
key
The key to use for storing the object in the DataStore Preferences.
serializer
The serializer to use for serializing the object.
dataStore
The DataStore instance to use for storing the preferences.